Skip to content

Commit ab5099e

Browse files
authored
Merge pull request #6 from kyaukyuai/chore/babel
Chore/babel
2 parents 16f5965 + ef47e08 commit ab5099e

File tree

4 files changed

+44
-30
lines changed

4 files changed

+44
-30
lines changed

.babelrc

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
{
2+
"presets": [
3+
[
4+
"@babel/preset-env",
5+
{
6+
"targets": {
7+
"edge": "17",
8+
"firefox": "60",
9+
"chrome": "67",
10+
"safari": "11.1"
11+
},
12+
"useBuiltIns": "usage",
13+
"corejs": "3.6.5",
14+
"debug": true
15+
}
16+
],
17+
"@babel/react"
18+
],
19+
"plugins": [
20+
[
21+
"babel-plugin-styled-components",
22+
{
23+
"ssr": false
24+
}
25+
],
26+
"@babel/plugin-syntax-dynamic-import",
27+
"@babel/plugin-syntax-import-meta",
28+
"@babel/plugin-proposal-class-properties",
29+
"@babel/plugin-proposal-json-strings",
30+
[
31+
"@babel/plugin-proposal-decorators",
32+
{
33+
"legacy": true
34+
}
35+
],
36+
"@babel/plugin-proposal-function-sent",
37+
"@babel/plugin-proposal-export-namespace-from",
38+
"@babel/plugin-proposal-numeric-separator",
39+
"@babel/plugin-proposal-throw-expressions"
40+
]
41+
}

.vscode/settings.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"cSpell.words": [
33
"cleanslate",
4+
"corejs",
45
"cssimportant"
56
],
67
"[typescriptreact]": {

package.json

Lines changed: 1 addition & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "typescript-react-embedded-widget-starter",
3-
"version": "0.0.8",
3+
"version": "0.0.9",
44
"description": "building an embedded widget with react and typescript",
55
"main": "dist/embedded-widget.js",
66
"author": "Yuya Kakui https://github.com/kyaukyuai",
@@ -21,33 +21,6 @@
2121
"storybook": "start-storybook -p 6006",
2222
"build-storybook": "build-storybook"
2323
},
24-
"babel": {
25-
"presets": [
26-
"airbnb"
27-
],
28-
"plugins": [
29-
[
30-
"babel-plugin-styled-components",
31-
{
32-
"ssr": false
33-
}
34-
],
35-
"@babel/plugin-syntax-dynamic-import",
36-
"@babel/plugin-syntax-import-meta",
37-
"@babel/plugin-proposal-class-properties",
38-
"@babel/plugin-proposal-json-strings",
39-
[
40-
"@babel/plugin-proposal-decorators",
41-
{
42-
"legacy": true
43-
}
44-
],
45-
"@babel/plugin-proposal-function-sent",
46-
"@babel/plugin-proposal-export-namespace-from",
47-
"@babel/plugin-proposal-numeric-separator",
48-
"@babel/plugin-proposal-throw-expressions"
49-
]
50-
},
5124
"dependencies": {
5225
"@styled-icons/ionicons-sharp": "^10.46.0",
5326
"@types/react": "^18.0.20",

webpack.config.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ module.exports = {
2323
use: [
2424
{
2525
loader: 'babel-loader',
26-
options: { presets: ['@babel/preset-env', '@babel/react'] },
2726
},
2827
{
2928
loader: 'ts-loader',
@@ -42,5 +41,5 @@ module.exports = {
4241
resolve: {
4342
extensions: ['.ts', '.tsx', '.js', '.json'],
4443
},
45-
target: 'web',
44+
target: ['web', 'es5'],
4645
}

0 commit comments

Comments
 (0)