☁️ Loving our new documentation website? Provide feedback in the CloudCannon Community! ✨

allow_implied_values

Table of contents

Description:

This key toggles whether CloudCannon will allow keys without values to imply a value of true when parsing key-value pairs in snippet parameters.

Setting this key to true will allow keys to be specified without values, which will be interpreted as true.

By default, this key is false (i.e., keys without values are not allowed).

Appears in:
└── Snippet Format
    └── allow_implied_values
Type:
boolean
Examples:

In this example, we have configured snippet format to allow implied values for keys without values.

Copied to clipboard
_snippets:
  example:
    snippet: <<example [[param]]>>
    params:
      param:
        parser: argument
        options:
          format:
            allow_implied_values: true
{
  "_snippets": {
    "example": {
      "snippet": "<<example [[param]]>>",
      "params": {
        "param": {
          "parser": "argument",
          "options": {
            "format": {
              "allow_implied_values": true
            }
          }
        }
      }
    }
  }
}
Open in a new tab