DefinitelyTyped/types/vuelidate
Brian Bugh e4da6e8797 vuelidate: Add function call signature to ValidationRule (#39206)
* Add function definition to ValidationRule

ValidationRule is a function that takes in parameters and then applies them to the inner validator function. The types are currently missing that allow this behavior. This is most useful when building composed functions out of the built-in validators, like so:

```typescript
export const greaterThanZero: ValidationRule = and(minValue(0), not((value: UserInput) => value == 0))
export const greaterThanOrEqualToZero: ValidationRule = minValue(0)
```

Vuelidate "withParams" reference that returns a ValidationRule function: bb23f01ab4/src/params.js (L36-L55)

* unknown -> any for TS < 3.0

* Fix unrelated noImplictAny for TypeScript@next
2019-10-22 15:25:02 -07:00
..
lib
index.d.ts
package.json
tsconfig.json
tslint.json
vue.d.ts
vuelidate-tests.ts
vuelidate.d.ts