Skip to content

Commit

Permalink
fix: Webpack resolving of commonjs imports
Browse files Browse the repository at this point in the history
Signed-off-by: Ferdinand Thiessen <rpm@fthiessen.de>
  • Loading branch information
susnux committed Feb 15, 2023
1 parent d0a7523 commit 9919afd
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
"version": "4.0.0",
"description": "",
"types": "dist/index.d.ts",
"main": "dist/index.js",
"module": "dist/index.es.js",
"main": "dist/index.cjs",
"module": "dist/index.mjs",
"type": "module",
"exports": {
".": {
"import": "./dist/index.es.js",
"require": "./dist/index.js"
"import": "./dist/index.mjs",
"require": "./dist/index.cjs"
},
"./dist/index.css": {
"import": "./dist/index.css",
Expand Down
4 changes: 2 additions & 2 deletions rollup.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,12 @@ export default [
input: 'lib/index.ts',
output: [
{
file: 'dist/index.js',
file: 'dist/index.cjs',
format: 'cjs',
sourcemap: true
},
{
file: 'dist/index.es.js',
file: 'dist/index.mjs',
format: 'esm',
sourcemap: true
}
Expand Down

0 comments on commit 9919afd

Please sign in to comment.