LIVR
LIVR copied to clipboard
Language Independent Validation Rules Specification
Are there plans or suggestions on how to handle conditional validation? For example, "if field 4 is true, then fields 4a and 4b are required, otherwise not".
An "Empty" rule, meaning the value must be empty. Useful in combination with "or" and "Not empty" ?
I really appreciate the idea of semantic error codes as opposed to numeric codes or messages. However, specifically in the case of `like`, exclusively returning the error code can lead...
Mb add some tests also Inconsistent behavior sample (erlang @Prots): http://livr-multi-playground.webbylab.com/#%7B%22rules%22%3A%22%7B%5Cn%20%20%20%20product_ids%3A%20'trololo'%5Cn%7D%22%2C%22input%22%3A%22%7B%5Cn%20%20%20%20product_ids%3A%201%5Cn%7D%22%7D
Inconsistent behavior sample: http://livr-multi-playground.webbylab.com/#%7B%22rules%22%3A%22%7B%5Cn%20%20link%3A%20'url'%5Cn%7D%22%2C%22input%22%3A%22%7B%5Cn%20%20link%3A%20'https%3A%2F%2Freciepts%2F12345678.pdf'%5Cn%7D%22%7D
Use case: `value: [{min_length: 10}]` When this validation fails it just returns `'TOO_LONG'` error code. However, quite often we need to show the user how many characters are actually expected....
Допустим есть правило на поле to:{'required', ....} и такое же на поле reg_id:{'required', ....}, но в запросе должно быть только одно из этих полей. Если есть поле to, то не...
Не совсем понятно почему спецификация допускает наличие в исходном пакете полей, для которых не заданы правила валидации? И в резалтсете мы получаем обрезанный набор исходных данных вместо ошибки валидации.
Hi there! Quite interesting project, but it would be great if you'll enhance README with few keystrokes how it is differs from existing schema definition languages (e.g. http://json-schema.org/)? At some...