1.0.1 • Published 8 years ago

redux-publish-action v1.0.1

Weekly downloads
5
License
Apache-2.0
Repository
github
Last release
8 years ago

redux-publish-action Circle CI

Redux middleware for simulating user's interaction in other user's browser using PbNub.

Using this middleware you can see what your users see in their application or you can show them what you see on your end. Useful for demos and debug sessions.

Usage

import { createStore, applyMiddleware } from 'redux';
import publishAction from 'redux-publish-action';

// Add PubNub publish and subscribe keys
let publishActionMiddleware = publishAction('pub-key-123', 'sub-key-123');
const store = createStore(
  yourApp,
  applyMiddleware(publishActionMiddleware)
);

For user that present his interaction - add ?sender=true to the application url

http://your.app.com?sender=true

For users that receive the intercations from the sender - add ?receiver=true to the application url

http://your.app.com?receiver=true

Installation

$ npm install redux-publish-action

Requirements

PbNub account with publish and subscribe keys.

License

Apache.