Skip to content

stephen-shopopop/node-typescript-workspace

Repository files navigation

Minimal node version Minimal npm version Maintenance Linux macOS Visual Studio Code

NODE typescript template workspace

Description

Template nodejs typescript with ts-standard

Installation nodejs via nvm (node version manager)

Contributing

Run package project:

npm run start -w=@stephen-shopopop/hello

// or run with ts-node
npm run dev -w=@stephen-shopopop/hello

Add package in workspace:

npm init --scope=@stephen-shopopop -y -w ./packages/hello

Add dependencies in package:

npm install abbrev -w @stephen-shopopop/hello

// uninstall
npm uninstall abbrev -w @stephen-shopopop/hello

Run test only in package:

npm test --packages/hello

Add reference package (npm recommended):

npm i ./packages/hello -w packages/mypackage

Add reference package (better reference):

"dependencies": {
  "@stephen-shopopop/hello": "*"
}

Version npm version:

npm version minor -w @stephen-shopopop/hello

Publish all package (optionnal):

npm publish --workspaces --access public

Extra:

// Start all projets on queueing
npm run start -ws

// Start all projets on queueing in dev mode
npm run dev -ws
  1. npm run test - Run tests.
  2. npm run build - Build each packages
  3. npm run build:extra - Build each package in dist isolate
  4. npm run lint - Run lint
  5. npm run lint:fix - Run lint autofix
  6. npm run typecheck - Run typecheck

Production

npm i --production

Docs

Summary

Package maintenance

A modern cli tool that keeps your deps fresh

npx taze -r

// major
npx taze major -r