Giter VIP home page Giter VIP logo

mkdocs_yaml_schema_plugin's People

Contributors

github-actions[bot] avatar jonca79 avatar smeds avatar

Watchers

 avatar

Forkers

jonca79

mkdocs_yaml_schema_plugin's Issues

Items without description breaks build

Currently a description for every second-level item is implicitly required, and not having one will result in a KeyError:

for key, values in items['properties'].items():
description = values['description'].replace("\n", "<br />")
for bold_key in self.bold_keys:
description = description.replace(bold_key, f"**{bold_key}**")
markdown_data += f"| {key} | {values['type']} | {description} |\n"

I guess it is reasonable to require a description to encourage better documentation, but it would probably be better if this was done explicitly. My suggestion is to either catch the exception and re-raise it with a better message to indicate what file and item is failing, or simply default to an empty description.

The same applies to the item type; should be there, but should probably be made explicit.

I'd be happy to submit a PR if we can decide on what solution would be best.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.