1
This commit is contained in:
9
plop-templates/utils.js
Normal file
9
plop-templates/utils.js
Normal file
@ -0,0 +1,9 @@
|
||||
exports.notEmpty = name => {
|
||||
return v => {
|
||||
if (!v || v.trim === '') {
|
||||
return `${name} is required`
|
||||
} else {
|
||||
return true
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user