Skip to content

Commit 27ed610

Browse files
pgerochipgerochi
authored andcommitted
feat: updated to react 17, webpack 5 and lowered filesize with dependencies to under 250mb.
1 parent b30cdf5 commit 27ed610

File tree

10 files changed

+5067
-15627
lines changed

10 files changed

+5067
-15627
lines changed

README.md

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,16 +5,10 @@
55

66

77
<p align="center">
8-
Tired of complicated starters with 200MB of dependencies which are hard to understand and modify? This is for you!
8+
Tired of complicated starters with more than 250MB of dependencies which are hard to understand and modify? This is for you!
99
This is a simple react application without redux, stylesheets or other set frameworks. It's only meant to get you started and the rest if up to you. Our goal for is to keep things simple and give you the freedom to select your own frameworks to add on top of this one.
1010
</p>
1111

12-
13-
<div class="center">
14-
[![Dependency Status](https://img.shields.io/david/ReactJSResources/react-webpack-babel.svg)](https://david-dm.org/dylang/npm-check)
15-
</div>
16-
17-
1812
### Demo
1913
https://murmuring-fjord-36537.herokuapp.com/
2014

config/webpack.config.js

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,13 @@ const config = {
2323
new HtmlWebpackPlugin({
2424
template: path.join(SRC_DIRECTORY, 'index.html')
2525
}),
26-
new CopyWebpackPlugin([
27-
{ from: path.join(SRC_DIRECTORY, 'assets'), to: path.join(ROOT_DIRECTORY, 'build') }
28-
])
26+
new CopyWebpackPlugin(
27+
{
28+
patterns: [
29+
{ from: path.join(SRC_DIRECTORY, 'assets'), to: path.join(ROOT_DIRECTORY, 'build') }
30+
]
31+
}
32+
)
2933
],
3034
module: {
3135
rules: [
Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,4 @@
11
const config = require('./webpack.config.js')
2-
const UglifyJsPlugin = require('uglifyjs-webpack-plugin')
32

43
config.mode = 'production'
5-
6-
config.optimization = {
7-
splitChunks: {
8-
chunks: 'all'
9-
}
10-
}
11-
12-
config.plugins = config.plugins.concat([
13-
new UglifyJsPlugin({
14-
sourceMap: true,
15-
extractComments: true
16-
})
17-
])
18-
194
module.exports = config

package-lock.json

Lines changed: 5031 additions & 15563 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 28 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"sass": "node-sass src/styles/index.scss build/index.css --output-style compressed",
1313
"build": "npm run clean && npm run sass && npm run webpack",
1414
"lint": "eslint src config",
15-
"dev": " webpack-dashboard -- webpack-dev-server --config config/webpack.config.dev.js",
15+
"dev": "webpack-cli serve --mode development --config config/webpack.config.dev.js",
1616
"test": "export NODE_ENV=test && jest",
1717
"start": "serve -s build"
1818
},
@@ -24,43 +24,32 @@
2424
"license": "MIT",
2525
"homepage": "https://github.com/ReactJSResources/react-webpack-babel#readme",
2626
"dependencies": {
27-
"@babel/cli": "^7.8.3",
28-
"@babel/core": "^7.8.3",
29-
"@babel/polyfill": "^7.8.3",
30-
"@babel/preset-env": "^7.8.3",
31-
"@babel/preset-react": "^7.8.3",
32-
"autoprefixer": "^9.7.4",
33-
"babel-eslint": "^10.0.3",
34-
"babel-loader": "^8.0.6",
27+
"@babel/core": "^7.12.3",
28+
"@babel/polyfill": "^7.12.1",
29+
"@babel/preset-env": "^7.12.1",
30+
"@babel/preset-react": "^7.12.5",
31+
"autoprefixer": "^10.0.2",
32+
"babel-loader": "^8.2.0",
3533
"babel-plugin-module-resolver": "^4.0.0",
36-
"babel-polyfill": "6.26.0",
37-
"copy-webpack-plugin": "^5.1.1",
38-
"css-loader": "^3.4.2",
34+
"copy-webpack-plugin": "^6.3.0",
35+
"css-loader": "^5.0.1",
3936
"enzyme": "^3.11.0",
40-
"enzyme-adapter-react-16": "^1.15.2",
41-
"eslint-import-resolver-babel-module": "^5.1.2",
42-
"eslint-plugin-jest": "^23.6.0",
43-
"file-loader": "^5.0.2",
37+
"enzyme-adapter-react-16": "^1.15.5",
38+
"file-loader": "^5.1.0",
4439
"history": "^4.10.1",
45-
"html-webpack-plugin": "^3.2.0",
40+
"html-webpack-plugin": "^4.5.0",
4641
"jest": "^24.9.0",
47-
"mini-css-extract-plugin": "^0.9.0",
48-
"node-sass": "^4.13.1",
49-
"postcss-cli": "^6.1.3",
50-
"react": "^16.12.0",
51-
"react-dom": "^16.12.0",
52-
"react-router-dom": "^5.1.2",
53-
"sass-loader": "^8.0.2",
54-
"semantic-release": "^15.14.0",
55-
"serve": "^11.3.0",
56-
"shx": "^0.3.2",
57-
"style-loader": "^1.1.3",
58-
"uglifyjs-webpack-plugin": "^2.2.0",
59-
"url-loader": "^3.0.0",
60-
"webpack": "^4.41.5",
61-
"webpack-cli": "^3.3.10",
62-
"webpack-dashboard": "^3.2.0",
63-
"webpack-dev-server": "^3.10.1"
42+
"node-sass": "^5.0.0",
43+
"react": "^17.0.1",
44+
"react-dom": "^17.0.1",
45+
"react-router-dom": "^5.2.0",
46+
"sass-loader": "^10.0.5",
47+
"serve": "^11.3.2",
48+
"shx": "^0.3.3",
49+
"style-loader": "^2.0.0",
50+
"webpack": "^5.4.0",
51+
"webpack-cli": "^4.2.0",
52+
"webpack-dev-server": "^3.11.0"
6453
},
6554
"jest": {
6655
"verbose": true,
@@ -81,11 +70,11 @@
8170
},
8271
"devDependencies": {
8372
"eslint": "^6.8.0",
84-
"eslint-config-standard": "^14.1.0",
85-
"eslint-plugin-import": "^2.20.0",
86-
"eslint-plugin-node": "^11.0.0",
73+
"eslint-config-standard": "^14.1.1",
74+
"eslint-plugin-import": "^2.22.1",
75+
"eslint-plugin-node": "^11.1.0",
8776
"eslint-plugin-promise": "^4.2.1",
88-
"eslint-plugin-react": "^7.18.0",
89-
"eslint-plugin-standard": "^4.0.1"
77+
"eslint-plugin-react": "^7.21.5",
78+
"eslint-plugin-standard": "^4.1.0"
9079
}
9180
}

src/assets/icons/favicon-32x32.png

-378 Bytes
Loading
-4.14 KB
Binary file not shown.
-13.6 KB
Binary file not shown.

src/assets/images/__loader.gif

-1.7 KB
Binary file not shown.

src/assets/images/dog.png

-492 KB
Loading

0 commit comments

Comments
 (0)