Phase 0: scaffold React (Vite + TS) app alongside Angular - #720
Open
vibhaseshadri-cognition wants to merge 1 commit into
Open
vibhaseshadri-cognition wants to merge 1 commit into
vibhaseshadri-cognition wants to merge 1 commit into
Conversation
- Vite + React 19 + TypeScript in react/ with React Router - Vitest + React Testing Library, Playwright e2e, ESLint + Prettier (shared config) - vite-plugin-pwa with manifest ported from src/manifest.json - Global SCSS and theme engine ported from src/styles.scss and src/app/shared/scss - GitHub Actions workflow for the react/ app Co-Authored-By: Vibha Seshadri <vibha.seshadri@cognition.ai>
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
PR 1 of the Angular -> React migration. Adds a self-contained
react/app next to the Angular source (nothing undersrc/is touched) so both coexist until parity is verified. No feature code yet — only tooling, global styles and a placeholderAppthat renders the theme wrapper (<div class="default"><div class="body-cover"/><div class="wrapper">…).Stack: Vite 7 + React 19 + TypeScript (strict), React Router (
react-router-domv7, v6-compatible API), Vitest + React Testing Library (jsdom), Playwright (replaces Protractor), ESLint 9 flat config + Prettier (samesingleQuote / tabWidth 4 / printWidth 120 / trailingComma es5as rootpackage.json),vite-plugin-pwa(WorkboxgenerateSW,autoUpdate, manifest ported fromsrc/manifest.json).Notes on the SCSS port:
_themes.scssnow uses@useinstead of@import,math.div($skull-size, 8)instead of/, andcolor.adjust(..., $lightness: -33%)instead ofdarken()— dart-sass removed/deprecated those forms; output is identical. Theapp-root:empty + .app-loadersplash selector becomes#root:empty + .app-loader.Also adds
.github/workflows/react.yml(lint, typecheck, unit tests w/ coverage, build, Playwright e2e) scoped toreact/**since the repo has no CI for the React side.Angular -> React file mapping
src/styles.scssreact/src/styles/styles.scsssrc/app/shared/scss/_media.scss,_theme_variables.scss,_themes.scssreact/src/styles/(same names)src/index.htmlreact/index.htmlsrc/manifest.jsonreact/vite.config.ts(VitePWA.manifest)ngsw-config.jsonreact/vite.config.ts(VitePWA.workbox)src/assets/**,src/favicon.icoreact/public/assets/**,react/public/favicon.icoe2e/(Protractor)react/e2e/+react/playwright.config.tskarma.conf.js/src/test.tsreact/vite.config.ts(test) +react/src/test/setup.tstslint.jsonreact/eslint.config.jsVerification
In
react/:npm run lint,npm run typecheck,npm test(1 smoke test),npm run build(emitssw.js,manifest.webmanifest, 43 precached entries),npm run e2e(1 Playwright test) all pass.Devin-Org: engineering
Link to Devin session: https://app.devin.ai/sessions/1e6f5b46badc4852993dc2299512cd3d
Open in Devin Desktop: https://app.devin.ai/desktop/session/1e6f5b46badc4852993dc2299512cd3d?variant=devin
Requested by: @vibhaseshadri-cognition