We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
const Schema = require('validate'); const _schema = new Schema({ user: { type: Object, required: true, }, }); let _user = { name: "gavin", longName: "GavinNie", }; console.log('_user 1', _user); _schema.validate(_user); console.log('_user 2', _user);
the console log: GL: getConfig -> env local _user 1 { name: 'gavin', longName: 'GavinNie' } _user 2 {}
The text was updated successfully, but these errors were encountered:
Same situation when _user is const, so the _user attribute is been deleted
const
Sorry, something went wrong.
I think it because the strict mode is enable by default and all field not from the _schema has been erased.
No branches or pull requests
the console log:
GL: getConfig -> env local
_user 1 { name: 'gavin', longName: 'GavinNie' }
_user 2 {}
The text was updated successfully, but these errors were encountered: