File tree Expand file tree Collapse file tree 4 files changed +540
-902
lines changed Expand file tree Collapse file tree 4 files changed +540
-902
lines changed Original file line number Diff line number Diff line change @@ -5,8 +5,8 @@ Fibonacci heap data structure for JavaScript.
5
5
See [ docs] ( https://aureooms.github.io/js-fibonacci-heap/index.html ) .
6
6
Parent is [ @aureooms/js-heap ] ( https://github.com/aureooms/js-heap ) .
7
7
8
- > :warning : The code needs a ES2015+ polyfill to run ( ` regeneratorRuntime ` ),
9
- > for instance [ @ babel/polyfill ] ( https://babeljs.io/docs/usage/polyfill ) .
8
+ > :warning : The code requires ` regeneratorRuntime ` to be defined, for instance by importing
9
+ > [ regenerator-runtime/runtime ] ( https://www.npmjs.com/package/regenerator-runtime ) .
10
10
11
11
``` js
12
12
let heap = new FibonacciHeap ( compare .increasing ) ;
Original file line number Diff line number Diff line change 1
1
# Usage
2
2
3
- > :warning : The code needs a ES2015+ polyfill to run ( ` regeneratorRuntime ` ),
4
- > for instance [ @ babel/polyfill ] ( https://babeljs.io/docs/usage/polyfill ) .
3
+ > :warning : The code requires ` regeneratorRuntime ` to be defined, for instance by importing
4
+ > [ regenerator-runtime/runtime ] ( https://www.npmjs.com/package/regenerator-runtime ) .
5
5
6
6
First, require the polyfill at the entry point of your application
7
7
``` js
8
- require ( ' @babel/polyfill ' ) ;
8
+ require ( ' regenerator-runtime/runtime ' );
9
9
// or
10
- import ' @babel/polyfill ' ;
10
+ import ' regenerator-runtime/runtime.js ' ;
11
11
```
12
12
13
13
Then, import the library where needed
Original file line number Diff line number Diff line change 8
8
" test/src/**/*"
9
9
],
10
10
"require" : [
11
- " @babel/polyfill " ,
11
+ " regenerator-runtime/runtime " ,
12
12
" @babel/register"
13
13
],
14
14
"timeout" : " 1m"
17
17
"presets" : [
18
18
" @babel/preset-env"
19
19
],
20
- "plugins" : [
21
- " @babel/plugin-proposal-async-generator-functions"
22
- ],
23
20
"env" : {
24
21
"development" : {
25
22
"sourceMaps" : " inline"
36
33
"@aureooms/js-heap-spec" : " 15.0.3" ,
37
34
"@babel/cli" : " 7.10.5" ,
38
35
"@babel/core" : " 7.11.1" ,
39
- "@babel/plugin-proposal-async-generator-functions" : " 7.10.5" ,
40
- "@babel/polyfill" : " 7.10.4" ,
41
36
"@babel/preset-env" : " 7.11.0" ,
42
37
"@babel/register" : " 7.10.5" ,
43
38
"ava" : " 3.11.1" ,
49
44
"esdoc-standard-plugin" : " 1.0.0" ,
50
45
"np" : " 6.3.2" ,
51
46
"nyc" : " 15.1.0" ,
47
+ "regenerator-runtime" : " 0.13.7" ,
52
48
"xo" : " 0.32.1"
53
49
},
54
50
"files" : [
You can’t perform that action at this time.
0 commit comments