Comparing version 1.3.3 to 1.3.4-beta.0
{ | ||
"name": "vue-types", | ||
"version": "1.3.3", | ||
"version": "1.3.4-beta.0", | ||
"description": "Prop types utility for Vue", | ||
@@ -30,3 +30,3 @@ "author": "Marco Solazzi", | ||
"test:types": "tsc -p ./types/test/tsconfig.json", | ||
"lint": "eslint src/*.js test/*.js", | ||
"lint": "eslint src/*.js test/*.js && npm run lint:types", | ||
"lint:types": "dtslint types", | ||
@@ -33,0 +33,0 @@ "start": "node ./server/index.js" |
@@ -5,3 +5,3 @@ // TypeScript Version: 2.8 | ||
export interface Constructor { | ||
new (...args: any[]): any; | ||
new(...args: any[]): any; | ||
} | ||
@@ -20,3 +20,3 @@ | ||
export type VueProp = VueTypeDef | PropOptions; | ||
export type VueProp<T = any> = VueTypeDef<T> | PropOptions<T>; | ||
@@ -28,3 +28,3 @@ export interface VueTypeInstanceOf<T extends Constructor> extends VueTypeDef<InstanceType<T>> { | ||
export interface VueTypeShape<T> extends VueTypeDef<T> { | ||
readonly def: <P extends defaultType<{ [K in keyof T]?: any }>>(def: P) => this & { default: P }; | ||
readonly def: <P extends defaultType<Partial<T>>>(def: P) => this & { default: P }; | ||
readonly loose: VueTypeLooseShape<T>; | ||
@@ -35,3 +35,3 @@ } | ||
readonly _vueTypes_isLoose: true; | ||
readonly def: <D extends defaultType<{ [K in keyof T]?: any } & { [key: string]: any }>>(def: D) => this & { default: D }; | ||
readonly def: <D extends defaultType<Partial<T> & { [key: string]: any }>>(def: D) => this & { default: D }; | ||
} | ||
@@ -75,3 +75,3 @@ | ||
readonly number: VueTypeDef<number>; | ||
readonly object: VueTypeDef<object>; | ||
readonly object: VueTypeDef<{ [key: string]: any }>; | ||
readonly integer: VueTypeDef<number>; | ||
@@ -82,8 +82,8 @@ readonly symbol: VueTypeDef<symbol>; | ||
instanceOf<C extends Constructor>(instanceConstructor: C): VueTypeInstanceOf<C>; | ||
oneOfType<T = Prop<any> | VueProp>(arr: T[]): VueTypeDef<T, any>; | ||
oneOfType(arr: Array<Prop<any> | VueProp<any>>): VueTypeDef; | ||
arrayOf<V extends any>(type: VueTypeDef<V> | Prop<V>): VueTypeArrayOf<V>; | ||
objectOf<T = any>(type: Prop<T> | VueProp): VueTypeObjectOf<T>; | ||
shape<S extends { [key: string]: VueProp | Prop<any> }>(obj: S): VueTypeShape<S>; | ||
objectOf<T = any>(type: Prop<T> | VueProp<T>): VueTypeObjectOf<T>; | ||
shape<T>(obj: { [K in keyof T]?: Prop<T[K]> | VueProp<T[K]> }): VueTypeShape<T>; | ||
} | ||
export const VueTypes: VueTypes; |
/*! vue-types - v1.3.3 | ||
/*! vue-types - v1.3.4-beta.0 | ||
* https://github.com/dwightjack/vue-types | ||
@@ -4,0 +4,0 @@ * Copyright (c) 2018 - Marco Solazzi; |
@@ -1,2 +0,2 @@ | ||
/*! vue-types - v1.3.3 | ||
/*! vue-types - v1.3.4-beta.0 | ||
* https://github.com/dwightjack/vue-types | ||
@@ -3,0 +3,0 @@ * Copyright (c) 2018 - Marco Solazzi; |
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
149977
2