feat: yup schema should not allow unknown keys

This commit is contained in:
Anoop M D
2022-10-14 22:42:46 +05:30
parent 8763ff2ad1
commit e46e3d5b22
3 changed files with 17 additions and 2 deletions

View File

@@ -8,7 +8,7 @@ const workspaceSchema = Yup.object({
.max(50, 'name must be 50 characters or less')
.required('name is required'),
collectionUids: Yup.array().of(uidSchema)
});
}).noUnknown(true).strict();
module.exports = {
workspaceSchema