Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit ecf553d

Browse filesBrowse files
committed
ref: Lemoncode#187 update 01 package.json
1 parent 333e5d7 commit ecf553d
Copy full SHA for ecf553d

File tree

Expand file treeCollapse file tree

2 files changed

+34
-33
lines changed
Filter options
Expand file treeCollapse file tree

2 files changed

+34
-33
lines changed

‎hooks/01_HelloReact/package.json

Copy file name to clipboardExpand all lines: hooks/01_HelloReact/package.json
+19-19Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -15,27 +15,27 @@
1515
"author": "Braulio Diez Botella",
1616
"license": "MIT",
1717
"devDependencies": {
18-
"@babel/cli": "^7.2.3",
19-
"@babel/core": "^7.2.2",
20-
"@babel/polyfill": "^7.2.5",
21-
"@babel/preset-env": "^7.3.1",
22-
"@types/react": "^16.8.3",
23-
"@types/react-dom": "^16.8.1",
18+
"@babel/cli": "^7.10.5",
19+
"@babel/core": "^7.10.5",
20+
"@babel/polyfill": "^7.10.4",
21+
"@babel/preset-env": "^7.10.4",
22+
"@types/react": "^16.9.43",
23+
"@types/react-dom": "^16.9.8",
2424
"awesome-typescript-loader": "^5.2.1",
25-
"babel-loader": "^8.0.5",
26-
"css-loader": "^2.1.0",
27-
"file-loader": "^3.0.1",
28-
"html-webpack-plugin": "^3.2.0",
29-
"mini-css-extract-plugin": "^0.5.0",
30-
"style-loader": "^0.23.1",
31-
"typescript": "^3.3.3",
32-
"url-loader": "^1.1.2",
33-
"webpack": "^4.29.3",
34-
"webpack-cli": "^3.2.3",
35-
"webpack-dev-server": "^3.1.14"
25+
"babel-loader": "^8.1.0",
26+
"css-loader": "^3.6.0",
27+
"file-loader": "^6.0.0",
28+
"html-webpack-plugin": "^4.3.0",
29+
"mini-css-extract-plugin": "^0.9.0",
30+
"style-loader": "^1.2.1",
31+
"typescript": "^3.9.7",
32+
"url-loader": "^4.1.0",
33+
"webpack": "^4.43.0",
34+
"webpack-cli": "^3.3.12",
35+
"webpack-dev-server": "^3.11.0"
3636
},
3737
"dependencies": {
38-
"react": "^16.8.2",
39-
"react-dom": "^16.8.2"
38+
"react": "^16.13.1",
39+
"react-dom": "^16.13.1"
4040
}
4141
}

‎hooks/01_HelloReact/webpack.config.js

Copy file name to clipboardExpand all lines: hooks/01_HelloReact/webpack.config.js
+15-14Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -8,20 +8,20 @@ var basePath = __dirname;
88
module.exports = {
99
context: path.join(basePath, "src"),
1010
resolve: {
11-
extensions: [".js", ".ts", ".tsx"]
11+
extensions: [".js", ".ts", ".tsx"],
1212
},
1313
entry: ["@babel/polyfill", "./index.tsx"],
1414
output: {
1515
path: path.join(basePath, "dist"),
16-
filename: "bundle.js"
16+
filename: "bundle.js",
1717
},
1818
devtool: "source-map",
1919
devServer: {
2020
contentBase: "./dist", // Content base
2121
inline: true, // Enable watch and live reload
2222
host: "localhost",
2323
port: 8080,
24-
stats: "errors-only"
24+
stats: "errors-only",
2525
},
2626
module: {
2727
rules: [
@@ -31,32 +31,33 @@ module.exports = {
3131
loader: "awesome-typescript-loader",
3232
options: {
3333
useBabel: true,
34-
babelCore: "@babel/core" // needed for Babel v7
35-
}
34+
babelCore: "@babel/core", // needed for Babel v7
35+
},
3636
},
3737
{
3838
test: /\.css$/,
39-
use: [MiniCssExtractPlugin.loader, "css-loader"]
39+
use: [MiniCssExtractPlugin.loader, "css-loader"],
4040
},
4141
{
4242
test: /\.(png|jpg|gif|svg)$/,
4343
loader: "file-loader",
4444
options: {
45-
name: "assets/img/[name].[ext]?[hash]"
46-
}
47-
}
48-
]
45+
name: "assets/img/[name].[ext]?[hash]",
46+
esModule: false,
47+
},
48+
},
49+
],
4950
},
5051
plugins: [
5152
//Generate index.html in /dist => https://github.com/ampedandwired/html-webpack-plugin
5253
new HtmlWebpackPlugin({
5354
filename: "index.html", //Name of file in ./dist/
5455
template: "index.html", //Name of template in ./src
55-
hash: true
56+
hash: true,
5657
}),
5758
new MiniCssExtractPlugin({
5859
filename: "[name].css",
59-
chunkFilename: "[id].css"
60-
})
61-
]
60+
chunkFilename: "[id].css",
61+
}),
62+
],
6263
};

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.