1 |
|
2 |
|
3 |
|
4 | import * as t from "ts-interface-checker";
|
5 |
|
6 |
|
7 | export const Transform = t.union(
|
8 | t.lit("jsx"),
|
9 | t.lit("typescript"),
|
10 | t.lit("flow"),
|
11 | t.lit("imports"),
|
12 | t.lit("react-hot-loader"),
|
13 | );
|
14 |
|
15 | export const SourceMapOptions = t.iface([], {
|
16 | compiledFilename: "string",
|
17 | });
|
18 |
|
19 | export const Options = t.iface([], {
|
20 | transforms: t.array("Transform"),
|
21 | jsxPragma: t.opt("string"),
|
22 | jsxFragmentPragma: t.opt("string"),
|
23 | enableLegacyTypeScriptModuleInterop: t.opt("boolean"),
|
24 | enableLegacyBabel5ModuleInterop: t.opt("boolean"),
|
25 | sourceMapOptions: t.opt("SourceMapOptions"),
|
26 | filePath: t.opt("string"),
|
27 | production: t.opt("boolean"),
|
28 | });
|
29 |
|
30 | const exportedTypeSuite = {
|
31 | Transform,
|
32 | SourceMapOptions,
|
33 | Options,
|
34 | };
|
35 | export default exportedTypeSuite;
|