global-api.js 804 B

12345678910111213141516171819202122
  1. declare interface GlobalAPI {
  2. cid: number;
  3. options: Object;
  4. config: Config;
  5. util: Object;
  6. extend: (options: Object) => Function;
  7. set: (obj: Object, key: string, value: any) => void;
  8. delete: (obj: Object, key: string) => void;
  9. nextTick: (fn: Function, context?: Object) => void;
  10. use: (plugin: Function | Object) => void;
  11. mixin: (mixin: Object) => void;
  12. compile: (template: string) => { render: Function, staticRenderFns: Array<Function> };
  13. directive: (id: string, def?: Function | Object) => Function | Object | void;
  14. component: (id: string, def?: Class<Component> | Object) => Class<Component>;
  15. transition: (id: string, def?: Object) => Object | void;
  16. filter: (id: string, def?: Function) => Function | void;
  17. // allow dynamic method registration
  18. [key: string]: any
  19. }