Istio Client
October 12, 2018 Β· View on GitHub
Naftis front end source code, based on React 16.4 / webpack4, notice some changes in the lifecycle of React 16.4 the front-end directory is under the src/ui of the project and directory.
develop
$ npm i
# open development
$ npm run dev
# build
$ npm run build
open http://localhost:5200
note: The port number can be modified in package.json
"dev": "cross-env NODE_ENV=development PORT=5200 node build/webpack.dev.config.js"
Js Specification
Project use Standard JSοΌThe JS file is automatically detected when submitting the file. If there is a problem, it needs to be fixed before it can be mentionedπ.
The react component file name takes the big hump rule, and the other file names take the small hump rule.
The public folder is used to store static files, Other folders that are used will be packaged into the project code.
Directory Structure
βββ build
β βββ webpack.base.config.js
β βββ webpack.dev.config.js
β βββ webpack.production.config.js
βββ package.json
βββ package-lock.json
βββ postcss.config.js
βββ README.md
βββ src
β βββ App.js
β βββ assets
β β βββ tpl
β β βββ trafficShifting.png
β βββ commons
β β βββlanguages
β β βββ index.js
β β βββ lib
β β βββ en-US.js
β β βββ zh-CN.js
β βββ components
β β βββ NavMenu
β β βββ index.js
β β βββ index.scss
β βββ config
β β βββ development.js
β β βββ index.js
β β βββ local.js
β β βββ production.js
β βββ index.html
β βββ index.js
β βββ public
β β βββ js
β β βββ cola.min.js
β β βββ d3.v4.min.js
β βββ redux
β β βββ actions
β β β βββ worktop
β β β βββ serviceStatus
β β β βββ index.js
β β βββ reducers
β β β βββ worktop
β β β βββ serviceStatus
β β β βββ index.js
β β βββ store
β β βββ index.js
β βββ utils
β β βββ base64.js
β β βββ md5.js
β βββ views
β βββ Worktop
β β βββ ServiceStatus
β β βββ index.js
β β βββ index.scss
β βββ index.js
βββ yarn.lock
βββ .babelrc
βββ .editorconfig