New issue
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
Configuration JSON schema #118
Conversation
Also, I automatically filled the |
README.md
Outdated
@@ -412,6 +412,7 @@ Here's a list of available display field types: | |||
* `url` - will render an anchor element with a clickable link | |||
* `image` - will render an image from the url | |||
* `colorbox` - will render a #RRGGBB hex string as an 80 x 20 pixel colored rectangle, overlaid with the hex color string | |||
* `boolean` - will green or red dot |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- will be
I think it's definitely should be part of the schema. |
You did right. It's a bit pain, but very important. |
@laudibert That's an awesome PR for an extremely important feature! Kudos! |
…nfortunately, the keyword "allOf" used for inheritance does not work with that option.
@dsternlicht, it should be ok now. The only problem that I encountered without any solution is that the |
I'm sorry to ask, but what's the meaning of What's the |
Yes but it works only one level at a time. Therefore it has to be defines for any object throughout the configuration. Not just at the root.
It allows to combine schemas for one schema definition. See here for a good explanation. In the RESTool case, it allowed me to define the common properties of all methods in one place and then combine it with the specific of each method. |
Got it. Does schemas support inheritance from another file as well? |
Yes, definitions can come from other files all loaded at the start of the app. I did not choose to do this though as I thought it might not be practical for people that are asking for the full schema. I could change it though. |
@laudibert no need, just ask for my own general knowledge :) |
Feature asked in #73.
Not sure if the schema should have
"additionalProperties": false
to help users realize when a field name was mistyped or if it's too constraining for when the schema might not be up to date with the code.