@digabi/typescript-config

1.0.2 • Public • Published

typescript-config

Shared Typescript config for the digabi project.

How to add to a new project?

Add the required dependencies:

$ npm install --save-dev @digabi/typescript-config

Add tsconfig.json to root folder

{
  "extends": "@digabi/typescript-config/root/tsconfig.json"
}

Add tsconfig.json to server folder

{
  "extends": "../tsconfig.json",
  "compilerOptions": {
    "outDir": "../dist"
  }
}

If you're have frontend, add tsconfig.json to public/js folder

{
  "extends": "@digabi/typescript-config/public/tsconfig.json"
}

Finally, modify .eslintrc.json in the project root. ./public/js/tsconfig.json is optional.

{
  "extends": "@digabi/eslint-config",
  "parserOptions": {
    "project": ["./public/js/tsconfig.json", "./tsconfig.json"]
  }
}

To compile server code, run

$ tsc --project server

Release new version:

npm version [patch, minor, major]
git push --follow-tags
npm publish

Readme

Keywords

none

Package Sidebar

Install

npm i @digabi/typescript-config

Weekly Downloads

848

Version

1.0.2

License

MIT

Unpacked Size

1.94 kB

Total Files

5

Last publish

Collaborators

  • digabi