Skip to content

Commit

Permalink
Merge pull request #110 from dmitri-gb/package-exports
Browse files Browse the repository at this point in the history
Use package.exports for better compatibility
  • Loading branch information
VolodymyrBaydalka authored May 1, 2024
2 parents f3fec58 + 687462e commit 589b3cf
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
8 changes: 6 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,11 @@
"files": [
"dist"
],
"type": "module",
"module": "dist/docx-preview.mjs",
"exports": {
".": {
"import": "./dist/docx-preview.mjs",
"require": "./dist/docx-preview.js"
}
},
"types": "dist/docx-preview.d.ts"
}
3 changes: 2 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"compilerOptions": {
"module": "ES2022",
"moduleResolution": "bundler",
"declaration": false,
"noImplicitAny": false,
"noEmitOnError": true,
Expand All @@ -12,7 +13,7 @@
"importHelpers": false,
"esModuleInterop": true,
"target": "ES2020",
"outDir": "dist",
"noEmit": true,
"lib": [
"ES2017",
"dom"
Expand Down

0 comments on commit 589b3cf

Please sign in to comment.