业务交流通
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.

index.d.ts 1.1KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. /// <reference types="miniprogram-api-typings" />
  2. interface VantComponentInstance {
  3. parent: WechatMiniprogram.Component.TrivialInstance;
  4. children: WechatMiniprogram.Component.TrivialInstance[];
  5. index: number;
  6. $emit: (
  7. name: string,
  8. detail?: unknown,
  9. options?: WechatMiniprogram.Component.TriggerEventOption
  10. ) => void;
  11. }
  12. export declare type VantComponentOptions<
  13. Data extends WechatMiniprogram.Component.DataOption,
  14. Props extends WechatMiniprogram.Component.PropertyOption,
  15. Methods extends WechatMiniprogram.Component.MethodOption
  16. > = {
  17. data?: Data;
  18. field?: boolean;
  19. classes?: string[];
  20. mixins?: string[];
  21. props?: Props;
  22. relation?: {
  23. relations: Record<string, WechatMiniprogram.Component.RelationOption>;
  24. mixin: string;
  25. };
  26. methods?: Methods;
  27. beforeCreate?: () => void;
  28. created?: () => void;
  29. mounted?: () => void;
  30. destroyed?: () => void;
  31. } & ThisType<
  32. VantComponentInstance &
  33. WechatMiniprogram.Component.Instance<
  34. Data & {
  35. name: string;
  36. value: any;
  37. } & Record<string, any>,
  38. Props,
  39. Methods
  40. > &
  41. Record<string, any>
  42. >;
  43. export {};