- no need to wait bundle & build in dev mode
- base on es module & es6
- bundle and build by webpack4 for production
npm init -y
init node projectnpm install https://github.com/miterfrants/swim.git
install swim from githubnode node_modules/swim/auto/initialize-project-structure.js
initialize swim structure of project
npm run swim-update
- open terminal and point to your project folder
cd ./src
point to src foldernode server.js
run dev server with nodejs- open
https://localhost/todos/
with browser
- open terminal with your project
cd ./dist
point to distribution folderFORCE_UPDATE=true NODE_ENV={envName} npm run swim-build
build and bundle js, css, htmlnode server.js
run bundle code with nodejs- open
https://localhost/todos/
with browser