Skip to content

Commit

Permalink
Typings for Typescript
Browse files Browse the repository at this point in the history
  • Loading branch information
eavichay committed Apr 13, 2017
1 parent 87c2bbe commit afb05a0
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 0 deletions.
34 changes: 34 additions & 0 deletions Slim.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
export declare class Slim {
static polyfill(url:string):void;
static tag(tag:string, template:string, clazz:any):void;
static getTag(clazz:Slim):string;
static plugin(phase:string, plugin:Function):void;
static registerCustomAttribute(attr:string, fn:Function):void;

createdCallback():void;
attachedCallback():void;
detachedCallback():void;
connectedCallback():void;
disconnectedCallback():void;

onBeforeCreated():void;
onCreated():void;
onAdded():void;
onRemoved():void;
onBeforeRender():void;
onAfterRender():void;
onBeforeUpdate():void
onAfterUpdate():void;

update():void;

render(template?:string):void;

find(selector:string):HTMLElement;
findAll(selector:string):HTMLElement[];
watch(prop:string, executor:Function):void;
callAttribute(attributeName:string, value:any);
useShadow:boolean;
isInteractive:boolean;
template:string;
}
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
"type": "git",
"url": "git+https://github.com/eavichay/slim.js.git"
},
"typings": "Slim.d.ts",
"author": "Avichay Eyal <[email protected]>",
"license": "MIT",
"bugs": {
Expand Down

0 comments on commit afb05a0

Please sign in to comment.