Skip to content

Commit

Permalink
fix: compatible esm/mjs requirements. #12
Browse files Browse the repository at this point in the history
  • Loading branch information
jaywcjlove committed Sep 16, 2021
1 parent a0a5e8f commit b131a8d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@
"prepack": "npm run build",
"start": "node lib/index.js",
"watch": "tsbb watch --disable-babel",
"build": "tsbb build --disable-babel",
"build": "tsbb build --disable-babel && npm run esm-fix",
"esm-fix": "tsc-esm-fix --target='lib' --ext='.js'",
"type-check": "tsc --noEmit",
"test": "tsbb test",
"coverage": "tsbb test --coverage"
},
Expand Down Expand Up @@ -52,6 +54,7 @@
"rehype-raw": "6.1.0",
"remark-parse": "10.0.0",
"remark-rehype": "9.0.0",
"tsc-esm-fix": "2.7.2",
"tsbb": "3.2.1"
}
}
4 changes: 2 additions & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { Plugin, Transformer } from 'unified';
import { Parent, NodeData, Node } from 'unist';
import { visit } from './visit.js';
import { visit } from './visit';

export * from './visit.js';
export * from './visit';

export type RehypeRewriteOptions = (node: NodeData<Parent>, index: number, parent: NodeData<Parent>) => void

Expand Down

0 comments on commit b131a8d

Please sign in to comment.