From 26105034da4fcce7ac883c899d781f016559310d Mon Sep 17 00:00:00 2001 From: ruki Date: Thu, 8 Nov 2018 00:38:48 +0800 Subject: switch to vuepress --- node_modules/nanobus/index.d.ts | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 node_modules/nanobus/index.d.ts (limited to 'node_modules/nanobus/index.d.ts') diff --git a/node_modules/nanobus/index.d.ts b/node_modules/nanobus/index.d.ts new file mode 100644 index 00000000..15aa0b5b --- /dev/null +++ b/node_modules/nanobus/index.d.ts @@ -0,0 +1,20 @@ +type NanobusListener = (...args: any[]) => void +type AttachListener = (eventName:string, listener:NanobusListener) => Nanobus + +declare class Nanobus { + private _name:string + private _startListeners:Array + private _listeners:{[key:string]:any} + constructor(name?:string) + emit:(eventName:string, ...args:any[]) => Nanobus + on:AttachListener + addListener:AttachListener + prependListener:AttachListener + once:AttachListener + prependOnceListener:AttachListener + removeListener:AttachListener + removeAllListeners(eventName:string):Nanobus + listeners(eventName:string):NanobusListener[] +} + +export = Nanobus \ No newline at end of file -- cgit v1.2.3