Giter Site home page Giter Site logo

metropolia-sssf-socket's Introduction

metropolia-sssf-socket

Socket app for week 4 assignment of Server-side Scripting Frameworks TX00CR77-3005 course at Metropolia UAS

What are namespaces in Socket.io? How they are different from rooms?

  • From socket.io docs: "A Namespace is a communication channel that allows you to split the logic of your application over a single shared connection (also called “multiplexing”)".
  • A namespace will be created by default when calling:
    const io = require('socket.io')();
    
  • Custom namespaces can be created:
    io.of("/music").on("connection", (socket) => { //... });
    io.of("/movies").on("connection", (socket) => { //... });
    
  • Rooms are different from namespaces: they are arbitrary channel that sockets can join and leave and they are created under a specific namespace.

Let us know how you could utilize websockets in your project.

  • My project is about video games review forum. Websockets can be applied to implement a real time review feed at the home page, where the newest reviews will be automatically added to the top of the feed.

metropolia-sssf-socket's People

Contributors

nguyen-tran-qk avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.