You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Update the project to use a npm workspaces monorepo structure. The monorepo should consist of 2 workspaces:
packages/api - contains the AWS Lambda functions and all application source code
packages/infra - contains the AWS CDK infrastructure as code
As part of this change to a monorepo structure:
Common packages should be hosted to the root package.json
Common scripts, such as clean, build, or test should be defined in the root package.json and reference the packages with flags like --workspaces --if-present
A base TypeScript configuration should be defined in the project root tsconfig.base.json and extended in the workspaces with overrides as needed
2. Switch from CommonJS to ESM modules
Both the AWS CDK and AWS Lambda functions support ESM modules. Update the project holistically to use ESM.
As part of this change, switch all of the monorepo workspaces/packages from testing with Jest to using Vitest. Vitest is the preferred testing framework for ESM modules. Create a base Vitest configuration file in the project root (vitest.config.ts) and then extend the base configuration, if needed, in the workspaces using the mergeConfig Vitest function.
3. Documentation
Review and update the project documentation after completing the changes. The documentation should reflect the changes to the project structure, npm scripts, Vitest, and any other outdated documentation.
4. AGENTS.md
Create a best practices AGENTS.md file for this project. Use the current .github/copilot-instructions. as a reference. After creating the AGENTS.md, update the copilot instructions file to simply point to the AGENTS.md file.
Activity