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

default

Table of contents

Description:

This key defines the default count for repeating literal parser configurations.

The value is a number that specifies how many times the literal should appear by default.

Appears in:
└── Snippet
    └── params
        └── *
            └── Repeating Literal Parser Config
                └── options
                    └── default
Type:
number
Examples:

In this example, we have configured a default count for repeating literal parser.

Copied to clipboard
_snippets:
  example:
    snippet: <<example [[literal_param]]>>
    params:
      literal_param:
        parser: repeating_literal
        options:
          literal: separator
          default: 1
{
  "_snippets": {
    "example": {
      "snippet": "<<example [[literal_param]]>>",
      "params": {
        "literal_param": {
          "parser": "repeating_literal",
          "options": {
            "literal": "separator",
            "default": 1
          }
        }
      }
    }
  }
}
Open in a new tab