Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

Commit

Permalink
fix(doc): fix #793, fix confuse bluebird patch doc (#794)
Browse files Browse the repository at this point in the history
  • Loading branch information
JiaLiPassion authored and mhevery committed Jun 2, 2017
1 parent b92b6e3 commit 0c5da04
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions NON-STANDARD-APIS.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,20 @@ Browser Usage:

After those steps, window.Promise will become a ZoneAware Bluebird Promise.

Node Usage:
Node Sample Usage:

```
require('zone-node.js');
require('zone.js');
const Bluebird = require('bluebird');
require('zone-bluebird.js');
require('zone.js/dist/zone-bluebird');
Zone[Zone['__symbol__']('bluebird')](Bluebird);
Zone.current.fork({
name: 'bluebird'
}).run(() => {
Bluebird.resolve(1).then(r => {
console.log('result ', r, 'Zone', Zone.current.name);
});
});
```

In NodeJS environment, you can choose to use Bluebird Promise as global.Promise
Expand Down

0 comments on commit 0c5da04

Please sign in to comment.