Commit 1204fdb
committed
Resolves #5706(FR-2195)
## Summary
- Added `resources/theme.json` to the `filesToWatch` array in `react/craco.config.cjs`
- This ensures that editing `theme.json` during development triggers an automatic full page reload, matching the existing pattern used for `config.toml`, `index.html`, and i18n translations
## What Changed
**`react/craco.config.cjs`** (1 line added):
```javascript
path.resolve(__dirname, '../resources/theme.json'),
```
Added after the `resources/i18n` watch entry. The existing `fs.watch` debounce mechanism (100ms timer sending `'static-changed'` WebSocket message) now covers `theme.json` changes automatically.
## Test Plan
- [ ] Start dev server with `pnpm run build:d`
- [ ] Edit `resources/theme.json` (e.g., change a color value)
- [ ] Verify the browser automatically reloads after the change
- [ ] Confirm the updated theme is applied without manual refresh
1 parent 4ca3d4c commit 1204fdb
1 file changed
Lines changed: 3 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
88 | 88 | | |
89 | 89 | | |
90 | 90 | | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
91 | 94 | | |
92 | 95 | | |
93 | 96 | | |
| |||
0 commit comments