Skip to content

Commit

Permalink
fix: Fix package exports (#5)
Browse files Browse the repository at this point in the history
* fix(npm): Fix the exports mapping

* chore(editor): Add words to the dictionary
  • Loading branch information
aaronclong authored Oct 30, 2024
1 parent 3cc383e commit 8edfb80
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 6 deletions.
3 changes: 2 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true
"editor.formatOnSave": true,
"cSpell.words": ["zxing"]
}
18 changes: 13 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,13 +34,21 @@
}
],
"exports": {
"types": "./dist/*.d.ts",
"import": "./dist/*.mjs",
"require": "./dist/*.cjs",
"default": "./dist/*.mjs"
"./barcode-api": {
"types": "./dist/barcode-api.d.ts",
"import": "./dist/barcode-api.mjs",
"require": "./dist/barcode-api.cjs",
"default": "./dist/barcode-api.mjs"
},
"./barcode-detector-zxing": {
"types": "./dist/barcode-detector-zxing.d.ts",
"import": "./dist/barcode-detector-zxing.mjs",
"require": "./dist/barcode-detector-zxing.cjs",
"default": "./dist/barcode-detector-zxing.mjs"
}
},
"scripts": {
"dev": "microbundle watch",
"dev": "rollup --watch -c rollup.config.js",
"install:peers": "npx npm-install-peers -- -y",
"build": "rollup -c rollup.config.js",
"lint": "eslint ./src"
Expand Down

0 comments on commit 8edfb80

Please sign in to comment.