Skip to content

Commit

Permalink
Change to use export map
Browse files Browse the repository at this point in the history
  • Loading branch information
wooorm committed Jul 8, 2023
1 parent 432836f commit 2054db1
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,7 @@
],
"sideEffects": false,
"type": "module",
"main": "index.js",
"types": "index.d.ts",
"exports": "./index.js",
"files": [
"lib/",
"index.d.ts",
Expand Down
9 changes: 5 additions & 4 deletions test.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
import assert from 'node:assert/strict'
import test from 'node:test'
import {findAndReplace} from 'mdast-util-find-and-replace'
import {u} from 'unist-builder'
import {findAndReplace} from './index.js'

test('findAndReplace', async function (t) {
await t.test('should expose the public api', async function () {
assert.deepEqual(Object.keys(await import('./index.js')).sort(), [
'findAndReplace'
])
assert.deepEqual(
Object.keys(await import('mdast-util-find-and-replace')).sort(),
['findAndReplace']
)
})

await t.test(
Expand Down

0 comments on commit 2054db1

Please sign in to comment.