An example code for the article Setting up Subpath Imports in a TypeScript Project.
-
Clone the repo
git clone https://github.com/vitalets/subpath-imports-typescript.git
-
Change directory to
subpath-imports-typescript
cd subpath-imports-typescript
-
Install dependencies
npm install
-
Run commands:
npm run tsc
- type-check the entire projectnpm run test
- run tests against the actual code insrc
npm run build
- compile the code fromsrc
into thedist
directorynpm start
- run the project from thedist
directorynpm run tsx
- run the project withtsx