Skip to content

Commit 7286e67

Browse files
committed
feat: include typedefinitions in npm package
fix nativescript-vue#262, fix nativescript-vue#263
1 parent d202dc4 commit 7286e67

File tree

2 files changed

+15
-13
lines changed

2 files changed

+15
-13
lines changed

index.d.ts

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,18 @@
11
// Typings for NativeScript-Vue
22
declare module 'nativescript-vue' {
3-
// import vue.js typings
4-
import Vue from 'vue';
3+
// import vue.js typings
4+
import Vue from 'vue';
55

6-
// creat a nativescript vue class that extends vue.js
7-
class NativeScriptVue extends Vue {
8-
/**
9-
* Registers NativeScript Plugin.
10-
* @param elementName Name of the element to use in your template
11-
* @param resolver function to register the element
12-
*/
13-
static registerElement(elementName: string, resolver: Function);
14-
}
6+
// creat a nativescript vue class that extends vue.js
7+
class NativeScriptVue extends Vue {
8+
/**
9+
* Registers NativeScript Plugin.
10+
* @param elementName Name of the element to use in your template
11+
* @param resolver function to register the element
12+
* @param meta meta associated with the element
13+
*/
14+
static registerElement(elementName: string, resolver: Function, meta?: any);
15+
}
1516

16-
export = NativeScriptVue;
17+
export = NativeScriptVue;
1718
}

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@
44
"description": "NativeScript and Vue integration",
55
"main": "dist/index.js",
66
"files": [
7-
"dist/index.js"
7+
"dist/index.js",
8+
"index.d.ts"
89
],
910
"scripts": {
1011
"test": "jest",

0 commit comments

Comments
 (0)