This package has been deprecated

Author message:

please use hoodie-plugin-global-share

hoodie-plugin-public-share

1.0.0 • Public • Published

hoodie-plugin-public-share Build Status

Installation:

hoodie install public-share

Usage:

Assuming you have a running hoodie setup.

Create a few documents you'd like to make publicly available:

var docs = [
  {
    name: 'sleep'
  },
  {
    name: 'eat'
  },
  {
    name: 'sleep some more'
  }
];
 
hoodie.store.add('tasks', docs).done(function(newDocs) { /.../ });

Make all 'tasks' publicly available:

hoodie.store.findAll('tasks').publish();

or publish a single task:

hoodie.store.find('tasks', 'taskID12345').publish();

Same goes for unpublishing:

hoodie.store.findAll('tasks').unpublish();
 
hoodie.store.find('tasks', 'taskID12345').unpublish();

Accessing publicly shared files:

hoodie.public.findAll('tasks').done(function (docs) {
  console.log(docs);  // logs all public docs
});

Testing:

grunt

Readme

Keywords

none

Package Sidebar

Install

npm i hoodie-plugin-public-share

Weekly Downloads

1

Version

1.0.0

License

none

Last publish

Collaborators

  • jan
  • gr2m
  • espy
  • caolan
  • svnlto