Skip to content

Commit

Permalink
migrate JS example to ESM
Browse files Browse the repository at this point in the history
  • Loading branch information
antonok-edm committed Aug 14, 2024
1 parent da57f65 commit 570e2df
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ It may be a good fit for yours, too!

See [docs.rs](https://docs.rs/adblock) for detailed API documentation.

Also check the [Rust example](./examples/example.rs) or the [NodeJS example](./js/example.js).
Also check the [Rust example](./examples/example.rs) or the [NodeJS example](./js/example.mjs).

### Optional features

Expand Down
4 changes: 2 additions & 2 deletions js/example.js → js/example.mjs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const adblockRust = require('adblock-rs');
const fs = require('fs');
import adblockRust from 'adblock-rs';
import fs from 'node:fs';
const dataPath = '../data/'

const debugInfo = true;
Expand Down

0 comments on commit 570e2df

Please sign in to comment.