kubernetes-fluent-client 1.5.0 → 1.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. package/dist/cli.d.ts +3 -0
  2. package/dist/cli.d.ts.map +1 -0
  3. package/dist/cli.js +39 -0
  4. package/dist/fetch.d.ts +1 -1
  5. package/dist/fetch.js +2 -2
  6. package/dist/fetch.test.js +1 -1
  7. package/dist/fluent/apply.js +1 -1
  8. package/dist/fluent/index.d.ts +1 -0
  9. package/dist/fluent/index.d.ts.map +1 -1
  10. package/dist/fluent/index.js +45 -3
  11. package/dist/fluent/types.d.ts +33 -21
  12. package/dist/fluent/types.d.ts.map +1 -1
  13. package/dist/fluent/types.js +1 -1
  14. package/dist/fluent/utils.d.ts +18 -7
  15. package/dist/fluent/utils.d.ts.map +1 -1
  16. package/dist/fluent/utils.js +19 -8
  17. package/dist/fluent/utils.test.js +1 -1
  18. package/dist/fluent/watch.d.ts +9 -2
  19. package/dist/fluent/watch.d.ts.map +1 -1
  20. package/dist/fluent/watch.js +19 -2
  21. package/dist/generate.d.ts +19 -0
  22. package/dist/generate.d.ts.map +1 -0
  23. package/dist/generate.js +165 -0
  24. package/dist/generate.test.d.ts +2 -0
  25. package/dist/generate.test.d.ts.map +1 -0
  26. package/dist/generate.test.js +256 -0
  27. package/dist/index.d.ts +1 -0
  28. package/dist/index.d.ts.map +1 -1
  29. package/dist/index.js +4 -1
  30. package/dist/kinds.d.ts +6 -0
  31. package/dist/kinds.d.ts.map +1 -1
  32. package/dist/kinds.js +53 -0
  33. package/dist/types.d.ts +1 -1
  34. package/dist/types.d.ts.map +1 -1
  35. package/package.json +13 -7
  36. package/src/cli.ts +44 -0
  37. package/src/fetch.test.ts +1 -1
  38. package/src/fetch.ts +2 -2
  39. package/src/fluent/apply.ts +1 -1
  40. package/src/fluent/index.ts +46 -4
  41. package/src/fluent/types.ts +34 -22
  42. package/src/fluent/utils.test.ts +1 -1
  43. package/src/fluent/utils.ts +19 -8
  44. package/src/fluent/watch.ts +22 -4
  45. package/src/generate.test.ts +266 -0
  46. package/src/generate.ts +189 -0
  47. package/src/index.ts +3 -0
  48. package/src/kinds.ts +53 -0
  49. package/src/types.ts +1 -1
@@ -0,0 +1,165 @@
1
+ "use strict";
2
+ // SPDX-License-Identifier: Apache-2.0
3
+ // SPDX-FileCopyrightText: 2023-Present The Kubernetes Fluent Client Authors
4
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
5
+ if (k2 === undefined) k2 = k;
6
+ var desc = Object.getOwnPropertyDescriptor(m, k);
7
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
8
+ desc = { enumerable: true, get: function() { return m[k]; } };
9
+ }
10
+ Object.defineProperty(o, k2, desc);
11
+ }) : (function(o, m, k, k2) {
12
+ if (k2 === undefined) k2 = k;
13
+ o[k2] = m[k];
14
+ }));
15
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
16
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
17
+ }) : function(o, v) {
18
+ o["default"] = v;
19
+ });
20
+ var __importStar = (this && this.__importStar) || function (mod) {
21
+ if (mod && mod.__esModule) return mod;
22
+ var result = {};
23
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
24
+ __setModuleDefault(result, mod);
25
+ return result;
26
+ };
27
+ Object.defineProperty(exports, "__esModule", { value: true });
28
+ exports.generate = void 0;
29
+ const client_node_1 = require("@kubernetes/client-node");
30
+ const fs = __importStar(require("fs"));
31
+ const path = __importStar(require("path"));
32
+ const quicktype_core_1 = require("quicktype-core");
33
+ const fetch_1 = require("./fetch");
34
+ const fluent_1 = require("./fluent");
35
+ const upstream_1 = require("./upstream");
36
+ /**
37
+ * Converts a CustomResourceDefinition to TypeScript types
38
+ *
39
+ * @param crd The CustomResourceDefinition to convert
40
+ * @param opts The options to use when converting
41
+ * @returns A promise that resolves when the CustomResourceDefinition has been converted
42
+ */
43
+ async function convertCRDtoTS(crd, opts) {
44
+ // Get the name of the kind
45
+ const name = crd.spec.names.kind;
46
+ const results = {};
47
+ for (const match of crd.spec.versions) {
48
+ // Get the schema from the matched version
49
+ const schema = JSON.stringify(match?.schema?.openAPIV3Schema);
50
+ // Create a new JSONSchemaInput
51
+ const schemaInput = new quicktype_core_1.JSONSchemaInput(new quicktype_core_1.FetchingJSONSchemaStore());
52
+ // Add the schema to the input
53
+ await schemaInput.addSource({ name, schema });
54
+ // Create a new InputData object
55
+ const inputData = new quicktype_core_1.InputData();
56
+ inputData.addInput(schemaInput);
57
+ // Generate the types
58
+ const out = await (0, quicktype_core_1.quicktype)({
59
+ inputData,
60
+ lang: opts.language || "ts",
61
+ rendererOptions: { "just-types": "true" },
62
+ });
63
+ let processedLines = out.lines;
64
+ // If using typescript, remove the line containing `[property: string]: any;`
65
+ if (opts.language === "ts" || opts.language === "typescript") {
66
+ processedLines = out.lines.filter(line => !line.includes("[property: string]: any;"));
67
+ }
68
+ // If the language is TypeScript and plain is not specified, wire up the fluent client
69
+ if (opts.language === "ts" && !opts.plain) {
70
+ processedLines.unshift(
71
+ // Add warning that the file is auto-generated
72
+ `// This file is auto-generated by kubernetes-fluent-client, do not edit manually\n`,
73
+ // Add the imports before any other lines
74
+ `import { GenericKind, RegisterKind } from "kubernetes-fluent-client";\n`);
75
+ // Replace the interface with a named class that extends GenericKind
76
+ const entryIdx = processedLines.findIndex(line => line.includes(`export interface ${name} {`));
77
+ // Replace the interface with a named class that extends GenericKind
78
+ processedLines[entryIdx] = `export class ${name} extends GenericKind {`;
79
+ // Add the RegisterKind call
80
+ processedLines.push(`RegisterKind(${name}, {`);
81
+ processedLines.push(` group: "${crd.spec.group}",`);
82
+ processedLines.push(` version: "${match.name}",`);
83
+ processedLines.push(` kind: "${name}",`);
84
+ processedLines.push(`});`);
85
+ }
86
+ const finalContents = processedLines.join("\n");
87
+ const fileName = `${name.toLowerCase()}-${match.name.toLowerCase()}`;
88
+ // If an output file is specified, write the output to the file
89
+ if (opts.directory) {
90
+ // Create the directory if it doesn't exist
91
+ fs.mkdirSync(opts.directory, { recursive: true });
92
+ // Write the file
93
+ const filePath = path.join(opts.directory, `${fileName}.${opts.language}`);
94
+ fs.writeFileSync(filePath, finalContents);
95
+ }
96
+ // Add the results to the array
97
+ results[fileName] = processedLines;
98
+ }
99
+ return results;
100
+ }
101
+ /**
102
+ * Reads a CustomResourceDefinition from a file, the cluster or the internet
103
+ *
104
+ * @param source The source to read from (file path, cluster or URL)
105
+ * @returns A promise that resolves when the CustomResourceDefinition has been read
106
+ */
107
+ async function readOrFetchCrd(source) {
108
+ const filePath = path.join(process.cwd(), source);
109
+ // First try to read the source as a file
110
+ try {
111
+ if (fs.existsSync(filePath)) {
112
+ const payload = fs.readFileSync(filePath, "utf8");
113
+ return (0, client_node_1.loadAllYaml)(payload);
114
+ }
115
+ }
116
+ catch (e) {
117
+ // Ignore errors
118
+ }
119
+ // Next try to parse the source as a URL
120
+ try {
121
+ const url = new URL(source);
122
+ // If the source is a URL, fetch it
123
+ if (url.protocol === "http:" || url.protocol === "https:") {
124
+ const { ok, data } = await (0, fetch_1.fetch)(source);
125
+ // If the request failed, throw an error
126
+ if (!ok) {
127
+ throw new Error(`Failed to fetch ${source}: ${data}`);
128
+ }
129
+ return (0, client_node_1.loadAllYaml)(data);
130
+ }
131
+ }
132
+ catch (e) {
133
+ // Ignore errors
134
+ }
135
+ // Finally, if the source is not a file or URL, try to read it as a CustomResourceDefinition from the cluster
136
+ try {
137
+ return [await (0, fluent_1.K8s)(upstream_1.CustomResourceDefinition).Get(source)];
138
+ }
139
+ catch (e) {
140
+ throw new Error(`Failed to read ${source} as a file, url or K8s CRD: ${e}`);
141
+ }
142
+ }
143
+ /**
144
+ * Generate TypeScript types from a K8s CRD
145
+ *
146
+ * @param opts The options to use when generating
147
+ * @returns A promise that resolves when the TypeScript types have been generated
148
+ */
149
+ async function generate(opts) {
150
+ const crds = await readOrFetchCrd(opts.source);
151
+ const results = {};
152
+ for (const crd of crds) {
153
+ if (!crd || crd.kind !== "CustomResourceDefinition" || !crd.spec?.versions?.length) {
154
+ // Ignore empty and non-CRD objects
155
+ continue;
156
+ }
157
+ // Add the results to the record
158
+ const out = await convertCRDtoTS(crd, opts);
159
+ for (const key of Object.keys(out)) {
160
+ results[key] = out[key];
161
+ }
162
+ }
163
+ return results;
164
+ }
165
+ exports.generate = generate;
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=generate.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generate.test.d.ts","sourceRoot":"","sources":["../src/generate.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,256 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ const globals_1 = require("@jest/globals");
7
+ const generate_1 = require("./generate");
8
+ const fs_1 = __importDefault(require("fs"));
9
+ const sampleYaml = `
10
+ # non-crd should be ignored
11
+ apiVersion: v1
12
+ kind: ConfigMap
13
+ metadata:
14
+ name: test
15
+ namespace: default
16
+ data:
17
+ any: bleh
18
+ ---
19
+ apiVersion: apiextensions.k8s.io/v1
20
+ kind: CustomResourceDefinition
21
+ metadata:
22
+ name: movies.example.com
23
+ spec:
24
+ group: example.com
25
+ names:
26
+ kind: Movie
27
+ plural: movies
28
+ scope: Namespaced
29
+ versions:
30
+ - name: v1
31
+ schema:
32
+ openAPIV3Schema:
33
+ type: object
34
+ description: Movie nerd
35
+ properties:
36
+ spec:
37
+ properties:
38
+ title:
39
+ type: string
40
+ author:
41
+ type: string
42
+ type: object
43
+ ---
44
+ # duplicate entries should not break things
45
+ apiVersion: apiextensions.k8s.io/v1
46
+ kind: CustomResourceDefinition
47
+ metadata:
48
+ name: movies.example.com
49
+ spec:
50
+ group: example.com
51
+ names:
52
+ kind: Movie
53
+ plural: movies
54
+ scope: Namespaced
55
+ versions:
56
+ - name: v1
57
+ schema:
58
+ openAPIV3Schema:
59
+ type: object
60
+ description: Movie nerd
61
+ properties:
62
+ spec:
63
+ properties:
64
+ title:
65
+ type: string
66
+ author:
67
+ type: string
68
+ type: object
69
+ ---
70
+ # should support multiple versions
71
+ apiVersion: apiextensions.k8s.io/v1
72
+ kind: CustomResourceDefinition
73
+ metadata:
74
+ name: books.example.com
75
+ spec:
76
+ group: example.com
77
+ names:
78
+ kind: Book
79
+ plural: books
80
+ scope: Namespaced
81
+ versions:
82
+ - name: v1
83
+ schema:
84
+ openAPIV3Schema:
85
+ type: object
86
+ description: Book nerd
87
+ properties:
88
+ spec:
89
+ properties:
90
+ title:
91
+ type: string
92
+ author:
93
+ type: string
94
+ type: object
95
+ - name: v2
96
+ schema:
97
+ openAPIV3Schema:
98
+ type: object
99
+ description: Book nerd
100
+ properties:
101
+ spec:
102
+ properties:
103
+ author:
104
+ type: string
105
+ type: object
106
+ served: true
107
+ storage: true
108
+ `;
109
+ globals_1.jest.mock("./fetch", () => ({
110
+ fetch: globals_1.jest.fn(),
111
+ }));
112
+ globals_1.jest.mock("./fluent", () => ({
113
+ K8s: globals_1.jest.fn(),
114
+ }));
115
+ (0, globals_1.describe)("CRD to TypeScript Conversion", () => {
116
+ const originalReadFileSync = fs_1.default.readFileSync;
117
+ globals_1.jest.isolateModules(() => {
118
+ globals_1.jest.spyOn(fs_1.default, "existsSync").mockReturnValue(true);
119
+ globals_1.jest.spyOn(fs_1.default, "readFileSync").mockImplementation((...args) => {
120
+ // Super janky hack due ot source-map-support calling readFileSync internally
121
+ if (args[0].toString().includes("test-crd.yaml")) {
122
+ return sampleYaml;
123
+ }
124
+ return originalReadFileSync(...args);
125
+ });
126
+ globals_1.jest.spyOn(fs_1.default, "mkdirSync").mockReturnValue(undefined);
127
+ globals_1.jest.spyOn(fs_1.default, "writeFileSync").mockReturnValue(undefined);
128
+ });
129
+ (0, globals_1.beforeEach)(() => {
130
+ globals_1.jest.clearAllMocks();
131
+ });
132
+ (0, globals_1.test)("converts CRD to TypeScript", async () => {
133
+ const options = { source: "test-crd.yaml", language: "ts" }; // specify your options
134
+ const actual = await (0, generate_1.generate)(options);
135
+ const expectedMovie = [
136
+ "// This file is auto-generated by kubernetes-fluent-client, do not edit manually\n",
137
+ 'import { GenericKind, RegisterKind } from "kubernetes-fluent-client";\n',
138
+ "/**",
139
+ " * Movie nerd",
140
+ " */",
141
+ "export class Movie extends GenericKind {",
142
+ " spec?: Spec;",
143
+ "}",
144
+ "",
145
+ "export interface Spec {",
146
+ " author?: string;",
147
+ " title?: string;",
148
+ "}",
149
+ "",
150
+ "RegisterKind(Movie, {",
151
+ ' group: "example.com",',
152
+ ' version: "v1",',
153
+ ' kind: "Movie",',
154
+ "});",
155
+ ];
156
+ const expectedBookV1 = [
157
+ "// This file is auto-generated by kubernetes-fluent-client, do not edit manually\n",
158
+ 'import { GenericKind, RegisterKind } from "kubernetes-fluent-client";\n',
159
+ "/**",
160
+ " * Book nerd",
161
+ " */",
162
+ "export class Book extends GenericKind {",
163
+ " spec?: Spec;",
164
+ "}",
165
+ "",
166
+ "export interface Spec {",
167
+ " author?: string;",
168
+ " title?: string;",
169
+ "}",
170
+ "",
171
+ "RegisterKind(Book, {",
172
+ ' group: "example.com",',
173
+ ' version: "v1",',
174
+ ' kind: "Book",',
175
+ "});",
176
+ ];
177
+ const expectedBookV2 = expectedBookV1
178
+ .filter(line => !line.includes("title?"))
179
+ .map(line => line.replace("v1", "v2"));
180
+ (0, globals_1.expect)(actual["movie-v1"]).toEqual(expectedMovie);
181
+ (0, globals_1.expect)(actual["book-v1"]).toEqual(expectedBookV1);
182
+ (0, globals_1.expect)(actual["book-v2"]).toEqual(expectedBookV2);
183
+ });
184
+ (0, globals_1.test)("converts CRD to TypeScript with plain option", async () => {
185
+ const options = { source: "test-crd.yaml", language: "ts", plain: true }; // specify your options
186
+ const actual = await (0, generate_1.generate)(options);
187
+ const expectedMovie = [
188
+ "/**",
189
+ " * Movie nerd",
190
+ " */",
191
+ "export interface Movie {",
192
+ " spec?: Spec;",
193
+ "}",
194
+ "",
195
+ "export interface Spec {",
196
+ " author?: string;",
197
+ " title?: string;",
198
+ "}",
199
+ "",
200
+ ];
201
+ const expectedBookV1 = [
202
+ "/**",
203
+ " * Book nerd",
204
+ " */",
205
+ "export interface Book {",
206
+ " spec?: Spec;",
207
+ "}",
208
+ "",
209
+ "export interface Spec {",
210
+ " author?: string;",
211
+ " title?: string;",
212
+ "}",
213
+ "",
214
+ ];
215
+ const expectedBookV2 = expectedBookV1
216
+ .filter(line => !line.includes("title?"))
217
+ .map(line => line.replace("v1", "v2"));
218
+ (0, globals_1.expect)(actual["movie-v1"]).toEqual(expectedMovie);
219
+ (0, globals_1.expect)(actual["book-v1"]).toEqual(expectedBookV1);
220
+ (0, globals_1.expect)(actual["book-v2"]).toEqual(expectedBookV2);
221
+ });
222
+ (0, globals_1.test)("converts CRD to Go", async () => {
223
+ const options = { source: "test-crd.yaml", language: "go" }; // specify your options
224
+ const actual = await (0, generate_1.generate)(options);
225
+ const expectedMovie = [
226
+ "// Movie nerd",
227
+ "type Movie struct {",
228
+ '\tSpec *Spec `json:"spec,omitempty"`',
229
+ "}",
230
+ "",
231
+ "type Spec struct {",
232
+ '\tAuthor *string `json:"author,omitempty"`',
233
+ '\tTitle *string `json:"title,omitempty"`',
234
+ "}",
235
+ "",
236
+ ];
237
+ const expectedBookV1 = [
238
+ "// Book nerd",
239
+ "type Book struct {",
240
+ '\tSpec *Spec `json:"spec,omitempty"`',
241
+ "}",
242
+ "",
243
+ "type Spec struct {",
244
+ '\tAuthor *string `json:"author,omitempty"`',
245
+ '\tTitle *string `json:"title,omitempty"`',
246
+ "}",
247
+ "",
248
+ ];
249
+ const expectedBookV2 = expectedBookV1
250
+ .filter(line => !line.includes("Title"))
251
+ .map(line => line.replace("v1", "v2"));
252
+ (0, globals_1.expect)(actual["movie-v1"]).toEqual(expectedMovie);
253
+ (0, globals_1.expect)(actual["book-v1"]).toEqual(expectedBookV1);
254
+ (0, globals_1.expect)(actual["book-v2"]).toEqual(expectedBookV2);
255
+ });
256
+ });
package/dist/index.d.ts CHANGED
@@ -5,6 +5,7 @@ export { fetch } from "./fetch";
5
5
  export { StatusCodes as fetchStatus } from "http-status-codes";
6
6
  export { K8s } from "./fluent";
7
7
  export { RegisterKind, modelToGroupVersionKind } from "./kinds";
8
+ export { GenericKind } from "./types";
8
9
  export * from "./types";
9
10
  export * as K8sClientNode from "@kubernetes/client-node";
10
11
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,IAAI,MAAM,YAAY,CAAC;AAEnC,oGAAoG;AACpG,OAAO,EAAE,IAAI,EAAE,CAAC;AAGhB,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAGhC,OAAO,EAAE,WAAW,IAAI,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAG/D,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAG/B,OAAO,EAAE,YAAY,EAAE,uBAAuB,EAAE,MAAM,SAAS,CAAC;AAEhE,cAAc,SAAS,CAAC;AAExB,OAAO,KAAK,aAAa,MAAM,yBAAyB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,IAAI,MAAM,YAAY,CAAC;AAEnC,oGAAoG;AACpG,OAAO,EAAE,IAAI,EAAE,CAAC;AAGhB,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAGhC,OAAO,EAAE,WAAW,IAAI,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAG/D,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAG/B,OAAO,EAAE,YAAY,EAAE,uBAAuB,EAAE,MAAM,SAAS,CAAC;AAGhE,OAAO,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAEtC,cAAc,SAAS,CAAC;AAExB,OAAO,KAAK,aAAa,MAAM,yBAAyB,CAAC"}
package/dist/index.js CHANGED
@@ -28,7 +28,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
28
28
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
29
29
  };
30
30
  Object.defineProperty(exports, "__esModule", { value: true });
31
- exports.K8sClientNode = exports.modelToGroupVersionKind = exports.RegisterKind = exports.K8s = exports.fetchStatus = exports.fetch = exports.kind = void 0;
31
+ exports.K8sClientNode = exports.GenericKind = exports.modelToGroupVersionKind = exports.RegisterKind = exports.K8s = exports.fetchStatus = exports.fetch = exports.kind = void 0;
32
32
  // Export kinds as a single object
33
33
  const kind = __importStar(require("./upstream"));
34
34
  exports.kind = kind;
@@ -45,5 +45,8 @@ Object.defineProperty(exports, "K8s", { enumerable: true, get: function () { ret
45
45
  var kinds_1 = require("./kinds");
46
46
  Object.defineProperty(exports, "RegisterKind", { enumerable: true, get: function () { return kinds_1.RegisterKind; } });
47
47
  Object.defineProperty(exports, "modelToGroupVersionKind", { enumerable: true, get: function () { return kinds_1.modelToGroupVersionKind; } });
48
+ // Export the GenericKind interface for CRD registration
49
+ var types_1 = require("./types");
50
+ Object.defineProperty(exports, "GenericKind", { enumerable: true, get: function () { return types_1.GenericKind; } });
48
51
  __exportStar(require("./types"), exports);
49
52
  exports.K8sClientNode = __importStar(require("@kubernetes/client-node"));
package/dist/kinds.d.ts CHANGED
@@ -1,4 +1,10 @@
1
1
  import { GenericClass, GroupVersionKind } from "./types";
2
+ /**
3
+ * Converts a model name to a GroupVersionKind
4
+ *
5
+ * @param key The name of the model
6
+ * @returns The GroupVersionKind for the model
7
+ */
2
8
  export declare function modelToGroupVersionKind(key: string): GroupVersionKind;
3
9
  /**
4
10
  * Registers a new model and GroupVersionKind to be used within the fluent API.
@@ -1 +1 @@
1
- {"version":3,"file":"kinds.d.ts","sourceRoot":"","sources":["../src/kinds.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAwgBzD,wBAAgB,uBAAuB,CAAC,GAAG,EAAE,MAAM,GAAG,gBAAgB,CAErE;AAED;;;;;GAKG;AACH,eAAO,MAAM,YAAY,UAAW,YAAY,oBAAoB,gBAAgB,SAUnF,CAAC"}
1
+ {"version":3,"file":"kinds.d.ts","sourceRoot":"","sources":["../src/kinds.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAujBzD;;;;;GAKG;AACH,wBAAgB,uBAAuB,CAAC,GAAG,EAAE,MAAM,GAAG,gBAAgB,CAErE;AAED;;;;;GAKG;AACH,eAAO,MAAM,YAAY,UAAW,YAAY,oBAAoB,gBAAgB,SAUnF,CAAC"}