Skip to content

Commit e03406c

Browse files
Add an IE11 compatible version of wrapper to distribution
1 parent 166f6fc commit e03406c

File tree

4 files changed

+706
-7
lines changed

4 files changed

+706
-7
lines changed

Diff for: .babelrc

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{
2+
"plugins": [
3+
"babel-plugin-transform-custom-element-classes"
4+
],
5+
"presets": [
6+
[
7+
"@babel/preset-env",
8+
{
9+
"modules": false,
10+
"targets": {
11+
"ie": "11"
12+
}
13+
}
14+
]
15+
]
16+
}

Diff for: package.json

+5-1
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,17 @@
2828
},
2929
"homepage": "https://github.com/vuejs/web-component-wrapper#readme",
3030
"devDependencies": {
31+
"@babel/core": "^7.0.0",
32+
"@babel/preset-env": "^7.0.0",
33+
"babel-plugin-transform-custom-element-classes": "^0.1.0",
3134
"eslint": "^4.16.0",
3235
"eslint-plugin-vue-libs": "^2.1.0",
3336
"http-server": "^0.11.1",
3437
"jest": "^22.1.4",
3538
"lint-staged": "^6.1.0",
3639
"puppeteer": "^1.0.0",
37-
"rollup": "^0.55.3",
40+
"rollup": "^0.65.2",
41+
"rollup-plugin-babel": "^4.0.3",
3842
"vue": "^2.5.13",
3943
"yorkie": "^1.0.3"
4044
},

Diff for: rollup.config.js

+10
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
import babel from 'rollup-plugin-babel'
2+
13
export default {
24
input: 'src/index.js',
35
output: [
@@ -9,6 +11,14 @@ export default {
911
format: 'iife',
1012
name: 'wrapVueWebComponent',
1113
file: 'dist/vue-wc-wrapper.global.js'
14+
},
15+
{
16+
format: 'iife',
17+
name: 'wrapVueWebComponent',
18+
file: 'dist/vue-wc-wrapper.ie11.js',
19+
plugins: [
20+
babel()
21+
]
1222
}
1323
]
1424
}

0 commit comments

Comments
 (0)