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 | t.lit("jest"),
|
14 | );
|
15 |
|
16 | export const SourceMapOptions = t.iface([], {
|
17 | compiledFilename: "string",
|
18 | });
|
19 |
|
20 | export const Options = t.iface([], {
|
21 | transforms: t.array("Transform"),
|
22 | jsxPragma: t.opt("string"),
|
23 | jsxFragmentPragma: t.opt("string"),
|
24 | enableLegacyTypeScriptModuleInterop: t.opt("boolean"),
|
25 | enableLegacyBabel5ModuleInterop: t.opt("boolean"),
|
26 | sourceMapOptions: t.opt("SourceMapOptions"),
|
27 | filePath: t.opt("string"),
|
28 | production: t.opt("boolean"),
|
29 | disableESTransforms: t.opt("boolean"),
|
30 | });
|
31 |
|
32 | const exportedTypeSuite = {
|
33 | Transform,
|
34 | SourceMapOptions,
|
35 | Options,
|
36 | };
|
37 | export default exportedTypeSuite;
|