Skip to content

Commit 813df9f

Browse files
committedSep 18, 2023
Change to use exports
1 parent 2eb2310 commit 813df9f

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed
 

‎package.json

+1-2
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,7 @@
2828
],
2929
"sideEffects": false,
3030
"type": "module",
31-
"main": "index.js",
32-
"types": "index.d.ts",
31+
"exports": "./index.js",
3332
"files": [
3433
"lib/",
3534
"index.d.ts",

‎test/index.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
22
* @typedef {import('mdast').Root} Root
3-
* @typedef {import('../index.js').Options} Options
3+
* @typedef {import('remark-frontmatter').Options} Options
44
*/
55

66
import assert from 'node:assert/strict'
@@ -9,11 +9,11 @@ import process from 'node:process'
99
import test from 'node:test'
1010
import {isHidden} from 'is-hidden'
1111
import {remark} from 'remark'
12-
import remarkFrontmatter from '../index.js'
12+
import remarkFrontmatter from 'remark-frontmatter'
1313

1414
test('remarkFrontmatter', async function (t) {
1515
await t.test('should expose the public api', async function () {
16-
assert.deepEqual(Object.keys(await import('../index.js')).sort(), [
16+
assert.deepEqual(Object.keys(await import('remark-frontmatter')).sort(), [
1717
'default'
1818
])
1919
})

0 commit comments

Comments
 (0)
Please sign in to comment.