shape-errors
3.0.3 • Public • Published shape-errors
v3.0.3
We follow [breaking].[feature].[fix] versioning.
const shape = require('shape-erros');
const s = shape({
user_id: (userId) => userExists(userId).then((result) => result ? null : 'invalid user'),
name: (name, {user_id}) => findUserByName(name).then((user) => user.id === user_id ? null : 'invalid name')
})
s.errors(data).then((errors) => {})
Versions
Version | Downloads (Last 7 Days) | Tag |
---|
3.0.3 | 1 | latest |
Version History
Package Sidebar
Install
Weekly Downloads