Recommended tooling
To offer a consistent developer experience, we recommend the following tooling.
npm (package manager)
We recommend you to use npm, the default package manager of Node.js. Other package managers (like Yarn or PNPM) usually work fine, but are not recommended to maintain consistency between projects.
Prettier (code formatting)
Prettier is an opinionated code formatter that is widely adopted in the industry and integrated into most IDEs. Maintaining a consistent code style across all Backpack-powered projects eliminates discussions about code style during code reviews.
Although Prettier is configurable, Backpack does not currently provide a specific preset. We recommend sticking to the default settings, but feel free to tweak it to your likings.
Note that you can also exclude specific code blocks using // prettier-ignore
.
ESLint (code linting)
ESLint is the recommended linting tool. It checks your code for common mistakes and bad practices, making your code safer and improving consistency.
Backpack provides a preset for your ESLint config that includes most recommended rules, and saves you some dependency management.
Vitest (testing)
Vitest is a modern testing framework that supports TypeScript out-of-the-box and makes testing easier, demanding little to no configuration, and requiring only a single dependency.
Vite (local development)
Vite is a build tool that speeds up local development. It is mostly adopted by frontend projects, but with @backpack/vite-plugin-lambda
you can also use it to run your AWS Lambda functions locally.