版博士V2.0程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

api.d.ts 920 B

123456789101112131415161718192021222324252627282930
  1. import { MagicString, SFCScriptBlock } from '@vue-macros/common';
  2. import { Program, TSType } from '@babel/types';
  3. declare const PROPS_VARIABLE_NAME: string;
  4. declare const EMIT_VARIABLE_NAME: string;
  5. interface TransformOptions {
  6. id: string;
  7. s: MagicString;
  8. offset: number;
  9. scriptSetup: SFCScriptBlock;
  10. setupAst: Program;
  11. isProduction: boolean;
  12. }
  13. interface Prop {
  14. name: string;
  15. definition?: string;
  16. typeParameter?: TSType;
  17. }
  18. declare function transformDefineProp(options: TransformOptions): Promise<void>;
  19. declare function transformDefineEmit({ setupAst, offset, s }: TransformOptions): void;
  20. declare function transformDefineSingle(code: string, id: string, isProduction: boolean): Promise<{
  21. code: string;
  22. map: any;
  23. } | undefined>;
  24. export { EMIT_VARIABLE_NAME, PROPS_VARIABLE_NAME, Prop, TransformOptions, transformDefineEmit, transformDefineProp, transformDefineSingle };