This is a template for writing TypeScript/Node projects using a somewhat opinionated dev stack. Choices made:
- Linting: ESLint (v9, using the flat config format)
- Code formatting: Prettier, set to run on file save
- Testing: Node built-in test runner.
This template fully supports ES Modules.
npm is used; yarn and pnpm are not tested.
- See GitHub's instructions to create your repository based on this template.
- Add your name to
LICENSEon the line below "Copyright (c) 2020 Dylan Sprague"; the format should be "Copyright (c) [year][your name]". - Update the repository and author fields in
package.json.
eslint-plugin-prettieris required to make ESLint report Prettier errors and show them as warnings in VS Code..prettierrc.cjsneeds the.cjsextension so it can usemodule.exports, which isn't valid when using ES modules.- The
typescript.preferences.importModuleSpecifierEnding: jsVS Code setting ensures that automatic imports will use a.jsfile ending, which is necessary when using Typescript with ES Modules.