Vale CMS Need more than a rule playground? Explore
Asset Explorer

JSONSchema

Every title and description in a JSON Schema, written in JSON or YAML.

view daselapi Vale ≥ 3.14.0 Source

Getting started

Save the file as config/views/JSONSchema.yml under your StylesPath, then:

[*.schema.{json,yml,yaml}]
BasedOnStyles = Vale

View = JSONSchema

JSONSchema.yml

Pull named scopes out of a file Vale can’t otherwise parse.
# A JSON Schema, in JSON or YAML: every `title` and `description`, at any
# depth. A property that happens to be named `title` is left alone.
#
#   [*.schema.{json,yml,yaml}]
#   BasedOnStyles = Vale
#   View = JSONSchema
engine: dasel
scopes:
  - name: title
    expr: '[$this].search(has("title")).map(title)'

  - name: description
    expr: '[$this].search(has("description")).map(description)'