1 | # plugin-typescript
|
2 |
|
3 | ## Install
|
4 |
|
5 | ```bash
|
6 | yarn add typescript @poi/plugin-typescript --dev
|
7 | ```
|
8 |
|
9 | ## Usage
|
10 |
|
11 | ```js
|
12 | // poi.config.js
|
13 | module.exports = {
|
14 | plugins: [
|
15 | require('@poi/plugin-typescript')(/* options */)
|
16 | ]
|
17 | }
|
18 | ```
|
19 |
|
20 | You will also need a `tsconfig.json` in your project, to make it work in Vue project, please check out https://vuejs.org/v2/guide/typescript.html
|
21 |
|
22 | ## API
|
23 |
|
24 | ### options
|
25 |
|
26 | #### options.loaderOptions
|
27 |
|
28 | Options for `ts-loader`.
|
29 |
|
30 | #### options.tsChecker
|
31 |
|
32 | Options for https://github.com/Realytics/fork-ts-checker-webpack-plugin
|
33 |
|
34 | Default:
|
35 |
|
36 | ```js
|
37 | {
|
38 | vue: true
|
39 | }
|
40 | ```
|
41 |
|
42 | ## License
|
43 |
|
44 | [MIT](https://oss.ninja/mit/egoist) © [EGOIST](https://github.com/egoist)
|