Skip to content

Commit

Permalink
Fix npm documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
gorhill committed Oct 6, 2024
1 parent ccbf957 commit 9233e6b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions platform/nodejs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ const { StaticNetFilteringEngine } = await import('@gorhill/ubo-core');
Create an instance of SNFE:

```js
const snfe = StaticNetFilteringEngine.create();
const snfe = await StaticNetFilteringEngine.create();
```

Feed the SNFE with filter lists -- `useLists()` accepts an array of
Expand All @@ -54,8 +54,8 @@ through the `raw` property, and optionally the name of the list through the

```js
await snfe.useLists([
fetch('easylist').then(raw => ({ name: 'easylist', raw })),
fetch('easyprivacy').then(raw => ({ name: 'easyprivacy', raw })),
fetch('easylist').then(r => r.text()).then(raw => ({ name: 'easylist', raw })),
fetch('easyprivacy').then(r => r.text()).then(raw => ({ name: 'easyprivacy', raw })),
]);
```

Expand Down

0 comments on commit 9233e6b

Please sign in to comment.