1.0.1-alpha.4055 • Published 2 years ago

jitsu-configurator-ui v1.0.1-alpha.4055

Weekly downloads
-
License
-
Repository
-
Last release
2 years ago

Available Scripts

Note: DO NOT USE NPM!

  • yarn install - get all dependencies (run before any script)
  • yarn start - dev application (with hot reload) will be started on http://localhost:9876
  • yarn build - build prod app, see build/ folder for results
  • yarn add (-D) - install and add package (-D - optional, use to install devDependency)
  • yarn stats - create a production build that can be further picked by bundle analyzers
  • yarn explore - analyze the bundle using source-map-explorer which is a recommended tool for CRA
  • yarn bundle - analyze the bundle using webpack-bundle-analyzer which has better UI but may fail to represent tree-shaking; for more info, refer to this discussion
  • yarn prettier:check - check all *.ts|tsx files in src directory for compliance
  • yarn prettier:write - fix all mistakes in *.ts|tsx files in src directory

Application configuration

The app recognize following environment variables. Those marked with '*' must be provided before building the app (or running it with yarn start)

Note: for adding new environment varialbles please list them in _webpack.config.js (look for webpack.DefinePlugin) and in env.js (look for getClientEnvironment)

Troubleshooting

  • rm -rf yarn.lock ./node_modules && yarn install

Initial development setup setup

ESLint

ESLint helps us to maintain the code style. Please, configure your IDE (or make sure you format code according the config in other way).

JetBrains IDE's (IDEA, WebStorm etc) config

There're two ways on how to configure IDEA

  1. Configure it to reformat code after saving the file each time: npm.io
  2. Import ESLint setting to internal IDEA formatter