@reboost/plugin-typescript
TypeScript icon, indicating that this package has built-in type declarations

0.21.0 • Public • Published

npm license

TypeScript Plugin

Transpile TypeScript files using the official TypeScript compiler. So that you can try out new TypeScript features without waiting.

NOTE: It does not checks for types. You have to do handle that by yourself. If you are using the CLI then you can use command tsc --noEmit (or tsc --noEmit --watch).

Usage

Setup

Install it using npm

npm i -D @reboost/plugin-typescript

Install typescript package, if not already installed

npm i typescript

Import it from the package

const { start } = require('reboost');
const TypeScriptPlugin = require('@reboost/plugin-typescript');

Add it to the plugins array

const { start } = require('reboost');
const TypeScriptPlugin = require('@reboost/plugin-typescript');

start({
  plugins: [
    TypeScriptPlugin({
      // Options
    })
  ]
})

Options

tsconfig

Type: string
Default: ./tsconfig.json

Path to the tsconfig file.

compatibleTypes

Type: string[]
Default: ['ts']

The file types that would be compiled by the plugin. Ex. If you set it to ['js', 'ts'], the plugin will also compile JavaScript files.

License

Licensed under the MIT License.

Package Sidebar

Install

npm i @reboost/plugin-typescript

Weekly Downloads

1

Version

0.21.0

License

MIT

Unpacked Size

8.27 kB

Total Files

6

Last publish

Collaborators

  • sarsamurmu