drone/web
2023-04-24 20:15:12 +00:00
..
.vscode Initial commit 2022-08-09 12:37:37 -07:00
config Reduce number of output files in production build from 400+ to 100+ (#363) 2023-03-02 14:08:12 -08:00
cypress Sync UI template with latest updates 2022-08-18 11:44:33 -07:00
docs Handle markdown links and videos (#357) 2023-02-27 11:15:57 -08:00
scripts Initial commit 2022-08-09 12:37:37 -07:00
src Merge branch 'code-213' of _OKE5H2PQKOUfzFFDuD4FA/default/CODE/gitness (#38) 2023-04-24 20:15:12 +00:00
.eslintignore Initial commit 2022-08-09 12:37:37 -07:00
.eslintrc.yml Render PR diff snapshot in the first thread comment (#239) 2023-01-22 12:32:31 -08:00
.gitignore Initial skeleton for Repository Resource View flow (#30) 2022-10-11 23:54:10 -07:00
.prettierrc.yml Initial commit 2022-08-09 12:37:37 -07:00
dist.go feat: [CODE-130]: CDN support experiment for Code in QA (#351) 2023-02-23 18:25:32 -08:00
jest.config.js Implement PR commenting prototype (#131) 2022-12-22 13:34:54 -08:00
jest.coverage.config.js Initial commit 2022-08-09 12:37:37 -07:00
package.json Resolve Editor slowness by replacing Editor React wrapper lib 2023-04-24 12:41:42 -07:00
README.md Initial commit 2022-08-09 12:37:37 -07:00
restful-react.config.js Redirect to Compare when editing a file with new branch created (#149) 2022-12-29 22:41:43 -08:00
tsconfig-eslint.json Initial commit 2022-08-09 12:37:37 -07:00
tsconfig.json Initial commit 2022-08-09 12:37:37 -07:00
yarn.lock Resolve Editor slowness by replacing Editor React wrapper lib 2023-04-24 12:41:42 -07:00

Sample Module UI

Prerequisites

yarn setup-github-registry

Local development

Change current directory to policy-mgmt project folder and run API server:

APP_ENABLE_UI=false APP_ENABLE_STANDALONE=true APP_TOKEN_JWT_SECRET=1234 APP_INTERNAL_TOKEN_JWT_SECRET=5678 APP_HTTP_BIND=localhost:3001 go run main.go server

Run the UI as a standalone app

yarn
yarn dev

Wait until Webpack build is done, then access http://localhost:3002/#/signin.

Note that you can point standalone UI app to a non-local backend service by creating a .env (under web or project folder) with content looks like:

TARGET_LOCALHOST=false
BASE_URL=https://qa.harness.io/gateway

Run the UI as a micro-frontend service

Due to an issue with Webpack (reason still unknown), you can't mount micro-frontend app inside NextGen UI when it's being run under Webpack development mode (aka yarn dev). To overcome the issue, run:

yarn
yarn micro:watch

The micro front-end UI will be served under http://localhost:3000. Run Core UI locally and navigate to the app within NextGen UI.

Build

UI build is integrated a a part of the backend build. See .drone.yml and Taskfile.yml for more information.