Add a New Module
Add a New Module
Section titled “Add a New Module”1. Create module folder
Section titled “1. Create module folder”Create src/modules/YourModule/ with a clear entry point (index.tsx or module.tsx + index.ts).
2. Register module
Section titled “2. Register module”Add module metadata and lazy import in src/utils/moduleRegistry.ts.
3. Confirm access flow
Section titled “3. Confirm access flow”Ensure backend/user module payload can include your new ModuleKey.
4. Validate rendering path
Section titled “4. Validate rendering path”/appshould still load normally./app/[module]should render your module when accessible.- Inaccessible module should return 404 behavior via
Handle.
5. Add docs
Section titled “5. Add docs”Create or update:
docs/modules/<module>.md- architecture notes if navigation or provider behavior changes
- reference docs if new shared primitives were introduced