create-v-model
Advanced tools
Comparing version 2.1.2 to 2.2.0
@@ -71,2 +71,11 @@ import { computed } from 'vue'; | ||
export { createModel, createModelFactory, modelProps }; | ||
/** | ||
* @arg {object} args | ||
* @arg {string} [args.modelName = 'modelValue'] - the NAME of the model in v-model:NAME | ||
* @returns {Array<string>} - emits specification | ||
*/ | ||
function modelEmits({ modelName = 'modelValue' } = {}) { | ||
return [`update:${modelName}`] | ||
} | ||
export { createModel, createModelFactory, modelEmits, modelProps }; |
{ | ||
"name": "create-v-model", | ||
"version": "2.1.2", | ||
"version": "2.2.0", | ||
"description": "create v-model bindings quickly and easily - without having to remember which props to use", | ||
@@ -28,3 +28,3 @@ "files": [ | ||
"postversion": "git push --follow-tags", | ||
"test": "uvu test" | ||
"test": "node test" | ||
}, | ||
@@ -34,11 +34,11 @@ "author": "Dave Honneffer <pearofducks@gmail.com>", | ||
"devDependencies": { | ||
"@vue/test-utils": "^2.0.0-beta.13", | ||
"abdomen": "^0.9.1", | ||
"jsdom": "^16.4.0", | ||
"rollup": "^2.35.1", | ||
"sinon": "^9.2.2", | ||
"typescript": "^4.3.5", | ||
"uvu": "^0.5.1", | ||
"vue": "^3.0.4" | ||
"@happy-dom/global-registrator": "^6.0.4", | ||
"@vue/test-utils": "^2.1.0", | ||
"happy-dom": "^6.0.4", | ||
"rollup": "^2.79.1", | ||
"sinon": "^14.0.0", | ||
"typescript": "^4.8.4", | ||
"uvu": "^0.5.6", | ||
"vue": "^3.2.40" | ||
} | ||
} |
@@ -46,4 +46,12 @@ /** | ||
/** | ||
* @arg {object} args | ||
* @arg {string} [args.modelName = 'modelValue'] - the NAME of the model in v-model:NAME | ||
* @returns {Array<string>} - emits specification | ||
*/ | ||
export function modelEmits({ modelName }?: { | ||
modelName?: string; | ||
}): Array<string>; | ||
/** | ||
* - Ref containing v-model | ||
*/ | ||
export type ModelComputed = import("vue").WritableComputedRef<any>; |
Sorry, the diff of this file is not supported yet
12552
203