2016-05-14 15:08:21 +08:00
|
|
|
declare interface GlobalAPI {
|
|
|
|
cid: number;
|
|
|
|
options: Object;
|
|
|
|
config: Config;
|
|
|
|
util: Object;
|
|
|
|
|
|
|
|
extend: (options: Object) => Function;
|
2017-03-03 12:07:42 +08:00
|
|
|
set: <T>(target: Object | Array<T>, key: string | number, value: T) => T;
|
|
|
|
delete: <T>(target: Object| Array<T>, key: string | number) => void;
|
2017-04-29 14:24:06 +08:00
|
|
|
nextTick: (fn: Function, context?: Object) => void | Promise<*>;
|
2016-05-14 15:08:21 +08:00
|
|
|
use: (plugin: Function | Object) => void;
|
|
|
|
mixin: (mixin: Object) => void;
|
|
|
|
compile: (template: string) => { render: Function, staticRenderFns: Array<Function> };
|
|
|
|
|
|
|
|
directive: (id: string, def?: Function | Object) => Function | Object | void;
|
|
|
|
component: (id: string, def?: Class<Component> | Object) => Class<Component>;
|
|
|
|
filter: (id: string, def?: Function) => Function | void;
|
|
|
|
|
|
|
|
// allow dynamic method registration
|
|
|
|
[key: string]: any
|
2017-05-15 16:01:30 +08:00
|
|
|
};
|