@rxap/schematics-ts-morph
Version:
This package provides utilities for manipulating TypeScript code using ts-morph, particularly for Angular and NestJS projects. It offers functions to add, coerce, and modify code elements like classes, methods, decorators, and imports. The package also in
12 lines (11 loc) • 890 B
TypeScript
import { Rule } from '@angular-devkit/schematics';
import { ClassDeclaration, SourceFile, WriterFunction } from 'ts-morph';
import { AbstractControl } from '../types/abstract-control';
import { CoerceOperationOptions as NEW_CoerceOperationOptions, TransformOperation, CoerceDtoClassOutput } from '@rxap/ts-morph';
import { CoerceOperationOptions } from './coerce-operation';
export interface CoerceOptionsOperationRuleOptions extends CoerceOperationOptions {
control: AbstractControl;
responseDtoName?: string;
}
export declare function BuildOptionsDtoDataMapperImplementation(classDeclaration: ClassDeclaration, moduleSourceFile: SourceFile, dto: CoerceDtoClassOutput | null, options: Readonly<NEW_CoerceOperationOptions>): TransformOperation<string | WriterFunction>;
export declare function CoerceOptionsOperationRule(options: Readonly<CoerceOptionsOperationRuleOptions>): Rule;