# MUST FOLLOW 0. **Always invoke the `local-expert` MCP** when dealing with web applications: call **`get_expert_knowledge`** with topic **`webapplications-design-system`** (for UI/design), and with **`webapplications`** when generating or structuring the app. Do not skip the design-system expert for any web app UI work. 1. **No `node -e`.** This project forbids `node -e` for any operation (file edits, config, shell automation). Use `replace_in_file` or `write_to_file` only. See **webapp-no-node-e.md**. # React Development & Stability Rules ## Terminal & Execution Strategy - **NEVER use `node -e`** for file manipulation, string replacement, or reading files. Forbidden. Use `replace_in_file` or `write_to_file` only. - ALWAYS use `replace_in_file` or `write_to_file` for code changes. - IF you must parse JSON (like package.json), use `jq` if available. Otherwise, read the file and process it internally. - ALWAYS use `npm` or `yarn` commands directly rather than writing custom Node scripts to trigger them. ## React & TypeScript Standards - Component Architecture: Prefer functional components with hooks. - File Naming: Use PascalCase for components (e.g., `Button.tsx`) and camelCase for hooks (e.g., `useAuth.ts`). - Imports: Use absolute paths (e.g., `@/components/...`) if the `tsconfig.json` or `vite.config.ts` supports it. - State: Default to `useState` for local state; avoid adding global state libraries unless requested. ## Reliability Protocol - Before running any build or test command, check for the existence of `node_modules`. If missing, prompt to run `npm install`. - When searching for code, use `search_files` with regex rather than trying to `grep` or `awk` through the terminal. - If a command fails twice, STOP and report the exact error to the user rather than attempting a third "creative" bash one-liner. # General app generation guidance Your goal is to create a functioning app on Salesforce platform. Do not mock UIs, but use tools at your disposal, such as custom objects, graphql API, Apex controllers in order to achieve your goal. **Home page must be populated:** The home page (root route) must never be left as the default template. Always populate it with real content—e.g. landing content, banners, tiles, hero, navigation to main features—tailored to the app or use case. Make it visually pleasing and purposeful. Do not leave placeholder or "Welcome to..." default content. **Replace default boilerplate:** Always replace default scaffold content (e.g. "React App", "Vite + React", default page titles, placeholder headings in index.html or App.tsx) with **project- or app-specific** names and copy. Do not leave generic "React App" or template placeholders in the UI or document title. **Navigation menu and placeholder name/design (critical — often missed):** **Build the navigation into the app layout** (`appLayout.tsx`) so every page shares the same nav. Always edit the **navigation menu** in that layout file: replace default nav items and labels with app-specific links and names; do not leave template "Home"/"About" or placeholder links. Always replace the **placeholder app name** in header, nav brand, footer, and `