@atscript/typescript 0.0.27 → 0.0.29

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.
package/dist/index.d.ts CHANGED
@@ -1,6 +1,12 @@
1
1
  import { TAtscriptPlugin } from '@atscript/core';
2
2
 
3
- declare const tsPlugin: () => TAtscriptPlugin;
3
+ interface TTsPluginOptions {
4
+ /**
5
+ * Render JSON schemas at build-time
6
+ */
7
+ preRenderJsonSchema?: boolean;
8
+ }
9
+ declare const tsPlugin: (opts?: TTsPluginOptions) => TAtscriptPlugin;
4
10
 
5
11
  interface TError {
6
12
  path: string;
@@ -130,4 +136,7 @@ interface TAnnotatedTypeHandle {
130
136
  }
131
137
  declare function isAnnotatedTypeOfPrimitive(t: TAtscriptAnnotatedType): boolean;
132
138
 
133
- export { type TAnnotatedTypeHandle, type TAtscriptAnnotatedType, type TAtscriptAnnotatedTypeConstructor, type TAtscriptTypeArray, type TAtscriptTypeComplex, type TAtscriptTypeDef, type TAtscriptTypeFinal, type TAtscriptTypeObject, type TMetadataMap, type TValidatorOptions, type TValidatorPlugin, type TValidatorPluginContext, Validator, ValidatorError, tsPlugin as default, defineAnnotatedType, isAnnotatedType, isAnnotatedTypeOfPrimitive };
139
+ type TJsonSchema = Record<string, any>;
140
+ declare function buildJsonSchema(type: TAtscriptAnnotatedType): TJsonSchema;
141
+
142
+ export { type TAnnotatedTypeHandle, type TAtscriptAnnotatedType, type TAtscriptAnnotatedTypeConstructor, type TAtscriptTypeArray, type TAtscriptTypeComplex, type TAtscriptTypeDef, type TAtscriptTypeFinal, type TAtscriptTypeObject, type TJsonSchema, type TMetadataMap, type TValidatorOptions, type TValidatorPlugin, type TValidatorPluginContext, Validator, ValidatorError, buildJsonSchema, tsPlugin as default, defineAnnotatedType, isAnnotatedType, isAnnotatedTypeOfPrimitive };