This package contains configuration files for TypeScript v4.3+
Require's tslib as a dependency for outputted code.
A collection of configuration files I use with tsconfig.json while working with TypeScript.
$ npm i --save-dev @futagoza/tsconfig
$ npm i tslib
Put the following into your tsconfig.json
(hint: you can rename this file when using tsc -p "custom name"
):
{
"extends": "@futagoza/tsconfig"
}
- Target ES2015
- Use CommonJS module generator
- Strict type checking
- Resolve JSON files
- Enables source maps (with the original source included in the source maps)
- Declaration files
- Always use Unix style (
lf
) new lines - Do not emit on errors
- Always import helpers from tslib to avoid duplication of TypeScript helpers
- Exclude's a number of directories that shouldn't contain
*.ts
source files - Includes commonly used directories for
*.ts
source files - Disable's automatic type acquisition
- Allows importing
*.js
exports into*.ts
files - Enforces consistent casing in filenames (when importing)
- Does not emit declarations for code that has an
@internal
annotation - Enable and disable options for my most common use cases
- Extends
@futagoza/tsconfig
- Target ES5
- Generate UMD modules
- Extends
@futagoza/tsconfig
- Target ES2020
- Generate ES2020 modules (ES2015 modules + dynamic imports +
import.meta
support)
- Extends
@futagoza/tsconfig
- Target ES2018
- Generate ES2015 modules
- Extends
@futagoza/tsconfig
- Target ES2015
- Use no module generator
- Extends
@futagoza/tsconfig
- Enables the
skipLibCheck
option - The
@types/node
type package is included without being referenced
- Extends
@futagoza/tsconfig/node/core.json
- Target ES2019 (used in Node.js 12)
- Extends
@futagoza/tsconfig/node/lts.json
- Generate ES2015 modules
- Extends
@futagoza/tsconfig/node/core.json
- Target ES2020 (used in Node.js 16)
- Extends
@futagoza/tsconfig/node/current.json
- Generate ES2020 modules (ES2015 modules + dynamic imports +
import.meta
support)
- Meant for use with NW.js or Electron
- Extends
@futagoza/tsconfig/browser/evergreen.json
- The
@types/node
type package is included without being referenced
- Extends
@futagoza/tsconfig
- Target ESNext (with library support for browsers, node and web-workers)
- Use ES module generator
Copyright © 2019+ Futago-za Ryuu
Released under the MIT License, http://opensource.org/licenses/MIT