joi
joi copied to clipboard
The most powerful data validation library for JS
#### Context * *node version*: 14.x (aws lambda function) * *module version*: 17.4.2 * *environment* (e.g. node, browser, native): node in aws lambda * *used with* (e.g. hapi application, another...
#### Context * *node version*: 14.17.0 * *module version with issue*: 17.6.0 * *last module version without issue*: N/A * *environment* (e.g. node, browser, native): node * *used with* (e.g....
**No breaking changes here. No existing tests were modified.** I know that many people want to see these features in Joi and I think this functionality is a must-have for...
- internals.assert was failing in detect empty strings as a message setting this same empty string as options parameter
Referencing #2797, I made a similar change that help `Joi.assert()` to assert value type accordingly. It uses a mixture of asserts condition and user defined type guard. - https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-7.html#assertion-functions -...
`joi.attempt` can return a template type rather than `any` Closes #2643
#### Context * *node version*: * *module version*: * *environment* (e.g. node, browser, native): * *used with* (e.g. hapi application, another framework, standalone, ...): * *any other relevant information*: ####...
The type issue that prevented strict object schemas from being nested has been resolved. The following is no longer incorrectly flagged as an error. ````ts interface ObjType { firstName: string;...
#### Context ``` Yarn Plugin Envinfo System: OS: macOS 11.6.6 CPU: (12) x64 Intel(R) Core(TM) i7-9750H CPU @ 2.60GHz Memory: 36.38 MB / 16.00 GB Shell: 5.8 - /bin/zsh Binaries:...
Based the comment on the matching code change here: https://github.com/sideway/address/blob/master/src/domain.ts