Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

feathers-primus

feathersjs1.5kMITdeprecated2.2.1TypeScript support: included

Feathers v3 is out and this module has moved to @feathersjs/primus and @feathersjs/primus-client. See https://docs.feathersjs.com/migrating.html for more information.

The Feathers Primus real-time API provider

feathers, feathers-plugin

readme

feathers-primus

Important: For Feathers v3.0.0 or later use the @feathersjs/primus module instead of feathers-primus.

Greenkeeper badge

Build Status Code Climate Test Coverage Dependency Status Download Status Slack Status

The Feathers Primus real-time API provider

About

This provider exposes Feathers services through Primus real-time APIs. It is compatible with Feathers 1.x and 2.x.

Note: For the full API documentation go to feathersjs.com/docs/providers.html.

Quick example

npm install ws

import feathers from 'feathers';
import primus from 'feathers-primus';

const app = feathers()
  .configure(primus({
    transformer: 'websockets'
  }, function(primus) {
    // Set up Primus authorization here
    primus.authorize(function (req, done) {
      req.feathers.data = 'Hello world';

      done();
    });
  }));

app.use('/todos', {
  get: function(id, params) {
    console.log(params.data); // -> 'Hello world'

    return Promise.resolve({
      id,
      description: `You have to do ${name}!`
    });
  }
});

License

Copyright (c) 2015

Licensed under the MIT license.

changelog

Change Log

v2.2.0 (2017-05-29)

Full Changelog

Closed issues:

  • An in-range update of feathers-hooks is breaking the build 🚨 #53
  • An in-range update of debug is breaking the build 🚨 #52
  • An in-range update of primus is breaking the build 🚨 #51
  • An in-range update of uws is breaking the build 🚨 #50
  • Expose headers and remote ip on feathers object #46
  • docs are out of date #28

Merged pull requests:

v2.1.0 (2017-03-01)

Full Changelog

Closed issues:

  • Issues with using feathers-primus/client and feathers-client #41
  • Any breaking change in 2.0.0? #39

Merged pull requests:

v2.0.0 (2016-12-02)

Full Changelog

Closed issues:

Merged pull requests:

v1.4.1 (2016-05-23)

Full Changelog

Merged pull requests:

v1.4.0 (2016-04-28)

Full Changelog

Merged pull requests:

v1.3.3 (2016-04-16)

Full Changelog

Merged pull requests:

v1.3.2 (2016-02-11)

Full Changelog

Merged pull requests:

  • Allow to instantiate a client instance #9 (daffl)

v1.3.1 (2016-02-09)

Full Changelog

Merged pull requests:

v1.3.0 (2016-02-09)

Full Changelog

Merged pull requests:

v1.2.1 (2016-01-21)

Full Changelog

v1.2.0 (2016-01-21)

Full Changelog

Merged pull requests:

  • Refactoring to use feathers-socket-commons that support event filtering #3 (daffl)

v1.1.0 (2016-01-10)

Full Changelog

Merged pull requests:

  • feathers-primus/client service and tests #1 (daffl)

v1.0.0 (2016-01-03)

* This Change Log was automatically generated by github_changelog_generator