Skip to content

pak11273/redux-socketio

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Socket.io for Redux

This module is built on top of zurfyx's implementation found (here)

Table of contents

Install

npm i -D redux-socketio or yarn i -D redux-socketio

Usage

import Socket from './services/socketio/index.js'
import {createStore, applyMiddleware} from 'redux'
import ioMiddleware from 'redux-socketio'
const SocketClient = new Socket()

const store = createStore(
  ... 
      applyMiddleware(ioMiddleware(SocketClient))
  ... 
)

...

export default store

// Note passing middleware as the third argument requires redux@>=3.1.0

See wiki for more details

To Do

  • Write tests
  • Node.js support
  • React-native support

Feel free to create PR for any of those tasks!

Known issues

  • Performance issues (#1)

License

MIT

About

A redux/socketIO middleware implementation

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published