Skip to content
This repository was archived by the owner on Sep 20, 2025. It is now read-only.

Commit 8e0340e

Browse files
[core] Remove the es module
1 parent ba27be6 commit 8e0340e

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

package.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,8 @@
33
"version": "0.5.8",
44
"description": "A React component that allow to bind events on the global scope",
55
"main": "dist/react-event-listener.cjs.js",
6-
"module": "dist/react-event-listener.esm.js",
76
"scripts": {
8-
"build": "rimraf dist && rollup -c",
7+
"build": "rimraf dist && rollup -c && rimraf dist/react-event-listener.esm.js",
98
"lint": "eslint . && echo \"eslint: no lint errors\"",
109
"size": "yarn build && size-limit",
1110
"test:unit": "NODE_ENV=test mocha",

rollup.config.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,17 +39,15 @@ export default [
3939
sizeSnapshot(),
4040
],
4141
},
42-
4342
{
4443
input,
4544
output: { file: pkg.main, format: 'cjs', exports: 'named' },
4645
external,
4746
plugins: [babel(getBabelOptions({ useESModules: false }))],
4847
},
49-
5048
{
5149
input,
52-
output: { file: pkg.module, format: 'es', exports: 'named' },
50+
output: { file: 'dist/react-event-listener.esm.js', format: 'es', exports: 'named' },
5351
external,
5452
plugins: [babel(getBabelOptions({ useESModules: true })), sizeSnapshot()],
5553
},

0 commit comments

Comments
 (0)