-
Notifications
You must be signed in to change notification settings - Fork 30
Schema type: "object"
fails on generate
#61
Comments
How are you running that fragment to cause the error? Could you provide the full path of the module which is throwing? Its not part of the generator, nor of |
Thanks for the reply, here are the steps to reproduce Generate App
Generate Service
Add Object with properties to schema:
Rerun service generate:
|
I misunderstood you when you mentioned "json-schema validations". I understood that as you trying to validate record contents using some of the exports from src/services/name/name.validate.?s. The name.schema.?s expects So, from the example, instead of "address": {
"type": "object",
"additionalProperties": { "type": "string" },
"maxProperties": 6,
"required": ["street", "postcode", "city", "country"]
}, rather like the following "personal": {
"type": "object",
"properties": {
"DOB": { "type": "string", "format": "date" },
"age": { "type": "integer", "minimum": 13 },
"gender": { "enum": ["female", "male"] }
}
"required": ["DOB", "age"],
"additionalProperties": false
},
`` |
I added an issue to support the notation used in |
Have been attempting some of the json-schema validations here:
https://code.tutsplus.com/tutorials/validating-data-with-json-schema-part-1--cms-25343
Appears to fail whenever using
type: 'object'
for example:Fails with this console error when running
feathers-plus generate all
:Is this a known/acceptable behaviour?
The text was updated successfully, but these errors were encountered: