improvement: omit deprecated fields in examples (via #4758)
This commit is contained in:
@@ -52,6 +52,9 @@ export const sampleFromSchema = (schema, config={}) => {
|
||||
let props = objectify(properties)
|
||||
let obj = {}
|
||||
for (var name in props) {
|
||||
if ( props[name] && props[name].deprecated ) {
|
||||
continue
|
||||
}
|
||||
if ( props[name] && props[name].readOnly && !includeReadOnly ) {
|
||||
continue
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user