/** * Bound the set of generated property-type interfaces a lexicon emits. * * Cloud provider schemas (ARM, CloudFormation, …) embed a named definition for * every nested object. Fully expanding all of them per-resource produces huge * `.d.ts` declarations (azure was ~273MB — see #438). This helper keeps only * the property types reachable from a resource's top-level properties within a * depth bound, plus a curated force-keep set; references that fall outside the * kept set are rewritten to `Record`. Enum references are * preserved. The input property refs are mutated in place. (#438, #440) */ /** A reference carrying a TypeScript type string, mutated in place when loosened. */ export interface BoundablePropertyRef { tsType: string; } /** A generated property type (named interface) and its properties. */ export interface BoundablePropertyType { name: string; specType: string; properties: BoundablePropertyRef[]; } export interface BoundPropertyTypeOptions { /** Maximum nesting depth of emitted property-type interfaces. */ maxDepth: number; /** * Definition-name substrings to always keep regardless of reachability/depth * (e.g. common nested shapes worth typing for authoring ergonomics). Matched * by substring against each property type's `specType`. */ curatedDefs?: Iterable; } /** * Filter `propertyTypes` to the bounded set and loosen out-of-set references. * Mutates the `tsType` of `resourceProps` and retained property types; returns * the retained property types. */ export declare function boundPropertyTypes(shortName: string, resourceProps: BoundablePropertyRef[], propertyTypes: PT[], enumNames: Set, options: BoundPropertyTypeOptions): PT[]; //# sourceMappingURL=bound-property-types.d.ts.map