@tenonhq/dovetail-typescript-plugin
v0.0.7
Published
TypeScript plugin for Dovetail
Keywords
Readme
@tenonhq/dovetail-typescript-plugin
Overview
This plugin allows you to run the TypeScript compiler on .ts files. Supports tsconfig.json files.
Installation
npm i -D @tenonhq/dovetail-typescript-pluginOptions
| Key | Type | Default | Description |
| ----------------- | ---------------------------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- |
| transpile | boolean | true | Whether or not the contents of the typescript file should be transpiled. Useful if you want to use Babel to transpile instead but still want type checking |
| compilerOptions | typescript.CompilerOptions | null | Same as compilerOptions in a tsconfig.json file |
Order of Configurations
- Load from
dove.config.jsoptions. - Check for
tsconfig.jsonfile and and override any overlapping values.
Example Usage
This example takes .ts files and only type checks them.
//dove.config.js
module.exports={
rules:{
match:/\.ts$/,
plugins:[
name:"@tenonhq/dovetail-typescript-plugin",
options:{
transpile:false
}
]
}
};