Ever wondered how you could set up a React project from scratch? This is the repo for you! I have also written up a blog tutorial to follow along.
Ever wondered how you could set up a React project from scratch? This is the repo for you! I have also written up a blog tutorial to follow along.
A ready to use simple webpack boilerplate.
npm installnpm start, localhost:8080 will open up in your default browserIf you prefer to install things yourself you can follow the instructions below
npm init and type your answers to the questions or you can run npm init -y to say yes to every question - you will get default settingsnpm i react react-dom -Snpm i babel-core babel-loader babel-preset-env babel-preset-react css-loader html-webpack-plugin style-loader webpack webpack-cli webpack-dev-server -D"start": "webpack-dev-server --mode development --open",
"build": "webpack --mode production"{
"presets": ["env", "react"]
}…import React from "react";
import ReactDOM from "react-dom";
const Index = () => {
return
;
};
ReactDOM.render(, document.getElementById("index"));
React and Webpack4
No open issues yet, or sync has not completed.