Skip to content

Commit 1a8bb57

Browse files
committed
Change to use exports
1 parent f2c89d6 commit 1a8bb57

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

package.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,7 @@
2626
],
2727
"sideEffects": false,
2828
"type": "module",
29-
"main": "index.js",
30-
"types": "index.d.ts",
29+
"exports": "./index.js",
3130
"files": [
3231
"lib/",
3332
"index.d.ts",

test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@ import assert from 'node:assert/strict'
22
import test from 'node:test'
33
import {h} from 'hastscript'
44
import {selectAll} from 'hast-util-select'
5-
import {truncate} from './index.js'
5+
import {truncate} from 'hast-util-truncate'
66

77
test('truncate', async function (t) {
88
await t.test('should expose the public api', async function () {
9-
assert.deepEqual(Object.keys(await import('./index.js')).sort(), [
9+
assert.deepEqual(Object.keys(await import('hast-util-truncate')).sort(), [
1010
'truncate'
1111
])
1212
})

0 commit comments

Comments
 (0)