From 2d4dc076fa38ae9c4aff5747c01f6963ad5e20bb Mon Sep 17 00:00:00 2001 From: Petyo Ivanov Date: Fri, 20 May 2016 09:17:28 +0300 Subject: [PATCH] feat: TypeScript definitions --- package.json | 1 + typings/Draggable.d.ts | 11 +++++++++++ 2 files changed, 12 insertions(+) create mode 100644 typings/Draggable.d.ts diff --git a/package.json b/package.json index 14faa8b..352e64a 100644 --- a/package.json +++ b/package.json @@ -7,6 +7,7 @@ "url": "https://github.com/telerik/kendo-draggable.git" }, "main": "dist/npm/js/Draggable.js", + "typings": "typings/Draggable.d.ts", "scripts": { "build-package": "gulp build-npm-package", "test": "gulp e2e", diff --git a/typings/Draggable.d.ts b/typings/Draggable.d.ts new file mode 100644 index 0000000..0216e77 --- /dev/null +++ b/typings/Draggable.d.ts @@ -0,0 +1,11 @@ +interface DraggableOptions { + press?: Function, + drag?: Function, + release?: Function +} + +export default class Draggable { + constructor(options?: DraggableOptions) + bindTo(element: Element) + destroy() +}