Skip to content
This repository was archived by the owner on Dec 2, 2020. It is now read-only.

Commit bd25c7a

Browse files
committed
add babel-plugin-add-module-exports
add babel-plugin-transform-decorators-legacy modify babel-preset-es2015 to babel-preset-es2015-ie
1 parent a2e6f78 commit bd25c7a

File tree

4 files changed

+10
-4
lines changed

4 files changed

+10
-4
lines changed

.babelrc

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
11
{
22
"presets": [
3-
"es2015",
3+
"es2015-ie",
44
"react",
55
"stage-0"
6+
],
7+
"plugins": [
8+
"add-module-exports",
9+
"transform-decorators-legacy"
610
]
711
}

package.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,9 @@
3232
"devDependencies": {
3333
"babel-cli": "^6.26.0",
3434
"babel-loader": "^7.1.2",
35-
"babel-preset-es2015": "^6.24.1",
35+
"babel-plugin-add-module-exports": "^0.2.1",
36+
"babel-plugin-transform-decorators-legacy": "^1.3.4",
37+
"babel-preset-es2015-ie": "^6.7.0",
3638
"babel-preset-react": "^6.24.1",
3739
"babel-preset-stage-0": "^6.24.1",
3840
"create-react-class": "^15.6.0",

src/DPlayer.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,4 +112,4 @@ DPlayerComponent.propTypes = {
112112
}),
113113
};
114114

115-
export default DPlayerComponent;
115+
export default DPlayerComponent;

webpack.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ const baseWebpackConfig = {
2323
amd: 'react',
2424
},
2525
[`dplayer`]: "DPlayer",
26-
[`dplayer/dist/DPlayer.min.css`]: "null",
26+
[`dplayer/dist/DPlayer.min.css`]: "undefined",
2727
},
2828
devtool: '#sourcemap',
2929
resolve: {

0 commit comments

Comments
 (0)