mirror of
https://github.com/FlipsideCrypto/DefinitelyTyped.git
synced 2026-02-06 10:56:53 +00:00
add vuedraggable type (#43117)
* add vuedraggable types * fix lint error
This commit is contained in:
parent
37cd32e962
commit
de4580242d
17
types/vuedraggable/index.d.ts
vendored
Normal file
17
types/vuedraggable/index.d.ts
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
// Type definitions for vuedraggable 2.23
|
||||
// Project: https://github.com/SortableJS/Vue.Draggable
|
||||
// Definitions by: Beomy <https://github.com/beomy>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 3.5
|
||||
|
||||
import { VueConstructor } from 'vue';
|
||||
|
||||
interface DraggableConstructor extends VueConstructor {
|
||||
props: any;
|
||||
data: () => any;
|
||||
watch: any;
|
||||
methods: any;
|
||||
}
|
||||
|
||||
export default draggable;
|
||||
export const draggable: DraggableConstructor;
|
||||
6
types/vuedraggable/package.json
Normal file
6
types/vuedraggable/package.json
Normal file
@ -0,0 +1,6 @@
|
||||
{
|
||||
"private": true,
|
||||
"dependencies": {
|
||||
"vue": ">=2.0.0"
|
||||
}
|
||||
}
|
||||
16
types/vuedraggable/tsconfig.json
Normal file
16
types/vuedraggable/tsconfig.json
Normal file
@ -0,0 +1,16 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": ["es6", "dom"],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"strictFunctionTypes": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": ["../"],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": ["index.d.ts", "vuedraggable-tests.ts"]
|
||||
}
|
||||
1
types/vuedraggable/tslint.json
Normal file
1
types/vuedraggable/tslint.json
Normal file
@ -0,0 +1 @@
|
||||
{ "extends": "dtslint/dt.json" }
|
||||
13
types/vuedraggable/vuedraggable-tests.ts
Normal file
13
types/vuedraggable/vuedraggable-tests.ts
Normal file
@ -0,0 +1,13 @@
|
||||
import Vue from 'vue';
|
||||
import draggable from 'vuedraggable';
|
||||
|
||||
new Vue({
|
||||
el: '#app',
|
||||
template: `<draggable v-model="list"></draggable>`,
|
||||
components: {
|
||||
draggable,
|
||||
},
|
||||
data: {
|
||||
list: []
|
||||
}
|
||||
});
|
||||
Loading…
Reference in New Issue
Block a user