Skip to content
This repository has been archived by the owner on Dec 2, 2018. It is now read-only.
/ meteor-unblock Public archive

A utils to unblock subscriptions, a this.unblock inside publications in Meteor version 1.7 or newer

License

Notifications You must be signed in to change notification settings

lh0x00/meteor-unblock

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Unblock helper inside Meteor Publications

build status

This package provides this.unblock inside Meteor publications. Unblock publications are one of most(may be a little bit less) requested feature and but it hasn't been implemented yet!

This package is like a new version of meteorhacks/unblock for Meteor the version 1.7 or later.

In this package, we also use the same way as meteorhacks/unblock to unblock the publications.

Why unblock?

Meteor executes DDP messages for a single client in a sequence. So, if one message takes a lot of time to process, that time will add up to all the messages. Fortunately, there is an API called as this.unblock help for other messages can start processing without waiting for the above method. But this is not available for Publications and this package is support for that feature.

Usage

Install

meteor add lamhieu:unblock

Use inside publications

Meteor.publish('publicationName', function() {
  this.unblock();
  // do somethings
});