|
17 | 17 | - Use **Batching** with `bulkWrite` (e.g., batches of 500) to maximize performance and minimize network roundtrips. |
18 | 18 | - Ensure **Idempotency** (safe to re-run) by using upserts or `$setOnInsert` where applicable. |
19 | 19 |
|
| 20 | +### Workspace map (core modules): |
| 21 | + |
| 22 | +- `apps/web` (`@courselit/web`): primary product app (Next.js app router), GraphQL API (`apps/web/graphql`), REST endpoints (`apps/web/app/api`), admin/public UI, auth, and payment entrypoints. |
| 23 | +- `apps/queue` (`@courselit/queue`): async/background job processing. |
| 24 | +- `apps/docs` (`@courselit/docs`): product documentation site. |
| 25 | +- `packages/common-models` (`@courselit/common-models`): shared domain types/constants used across apps/packages. |
| 26 | +- `packages/orm-models` (`@courselit/orm-models`): shared DB schemas/models for Mongo-backed entities. |
| 27 | +- `packages/common-logic` (`@courselit/common-logic`): shared business logic that should not stay app-specific. |
| 28 | +- `packages/components-library` (`@courselit/components-library`): reusable UI components/hooks (e.g. forms, media selector, upload hooks). |
| 29 | +- `packages/page-blocks` (`@courselit/page-blocks`): page builder blocks/widgets and related rendering logic. |
| 30 | +- `packages/page-primitives` (`@courselit/page-primitives`): foundational themed UI primitives. |
| 31 | +- `packages/page-models` (`@courselit/page-models`): theme/page model definitions consumed by rendering/editor flows. |
| 32 | +- `packages/text-editor` (`@courselit/text-editor`): rich text editor used in admin/content editing. |
| 33 | +- `packages/email-editor` (`@courselit/email-editor`): email template/editor model and rendering structures. |
| 34 | +- `packages/utils` (`@courselit/utils`): shared utility helpers. |
| 35 | +- `packages/icons` (`@courselit/icons`): shared icon exports. |
| 36 | +- `packages/scripts` (`@courselit/scripts`): reusable maintenance scripts (not one-off migrations). |
| 37 | +- `packages/tailwind-config`, `packages/tsconfig`: shared config workspaces. |
| 38 | + |
20 | 39 | ## Documentation tips |
21 | 40 |
|
22 | 41 | - We manage product's documentation in `apps/docs`. |
|
0 commit comments