Skip to content

Commit 43a0364

Browse files
committed
feat: export lib files
This exposes the lib files, so `domToReact` can be imported without importing all of `domhandler`, which reduces bundle size. It also exposes `attributesToProps`, which is useful (at least in my project) You can import like `import domToReact from 'html-react-parser/lib/dom-to-react'`
1 parent 5475f2c commit 43a0364

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Diff for: package.json

+4
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@
1111
"import": "./index.mjs",
1212
"require": "./index.js"
1313
},
14+
"./lib/*": {
15+
"types": "./lib/*.d.ts",
16+
"default": "./lib/*.js"
17+
},
1418
"./package.json": "./package.json"
1519
},
1620
"scripts": {

0 commit comments

Comments
 (0)