JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • 0
  • Score
    100M100P100Q30511F
  • License MIT

Base tsconfig for oakfinch projects

Package Exports

  • @oakfinch/tsconfig

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@oakfinch/tsconfig) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

tsconfig

Base tsconfig for oakfinch projects


license TypeScript

latest release on npm latest release on github


github


Installation

Using npm:

npm install --save-dev @oakfinch/tsconfig

Using yarn:

yarn add -D @oakfinch/tsconfig

Usage

Basic usage

Defaults to a commonjs build with an es5 target, output to the ./dist directory

tsconfig.json

{
  "extends": "@oakfinch/tsconfig"
}

Explicitly specify a cjs build

tsconfig.json

{
  "extends": "@oakfinch/tsconfig/tsconfig.cjs.json"
}

ESM build

tsconfig.json

{
  "extends": "@oakfinch/tsconfig/tsconfig.esm.json",
}

Multiple builds

You can create multiple builds by having multiple config files, and then specifying them with the --build flag.

When using multiple builds, you'll want to reference the files as @oakfinch/tsconfig/<type> rather than @oakfinch/tsconfig/tsconfig.<type>.json to avoid the builds overriding each other due to having the same outDir.

tsconfig.json

{
  "extends": "@oakfinch/tsconfig/tsconfig.cjs.json"
}

tsconfig.esm.json

{
  "extends": "@oakfinch/tsconfig/tsconfig.esm.json",
}
tsc --build tsconfig.json tsconfig.esm.json