1.1.1 • Published 7 years ago

catberry-socket.io v1.1.1

Weekly downloads
6
License
MIT
Repository
github
Last release
7 years ago

Catberry Socket.io Adapter

Gitter

It is an adapter for Socket.io engine that makes possible to use it from Catberry application.

Installation

npm install catberry-socket.io --save

Usage

You can use the adapter in ./server.js as following:

const cat = catberry.create(config);
const server = http.createServer(app);

const socketIo = require('catberry-socket.io');
socketIo.register(cat.locator);
cat.locator.resolve('socket.ioProvider').registerServer(server);

server.listen(config.server.port);

In ./browser.js as following:

const cat = catberry.create(config);

const socketIo = require('catberry-socket.io');
socketIo.register(cat.locator);
cat.locator.resolve('socket.ioProvider').connectToServer();

In ./build.js as following:

const cat = catberry.create(config);

const socketIo = require('catberry-socket.io');
socketIo.register(cat.locator);

In fact, Catberry CLI does it for you.

Contributing

There are a lot of ways to contribute:

Miha Vizovišek miha.vizovisek@gmail.com

Denis Rechkunov denis.rechkunov@gmail.com

1.1.1

7 years ago

1.1.0

8 years ago

1.0.0

8 years ago