Skip to main content
Skip table of contents

Allow/Block Macros

Description

Control which macros can be used on a page by adding them to either a blocklist or an allowlist.

Configuration options:

Allowlist

(with optional parameter values)

Use the picker to choose macros that are allowed to be used. Every macro not chosen will be marked as a quality issue in the report.

You can narrow the focus of this rule to macros using a specific configuration by specifying parameters and search for specific values.

For instance, if you would prefer that

Blocklist

(with optional parameter values)

Use the picker to choose macros that should not be used. Each use of the macros in the list will be marked as a quality issue in the report.

You can narrow the focus of this rule by specifying parameters and values as outlined above.

Advanced Mode Example Settings

YAML
# Warn users not to include certain macros in their documents

rule: macros
level: major
disabled: false
blocked:
  - element: iframe
    parameters: {}
description: We do not allow the use of iframes in this space, please remove.

# Warn users not to use specific configurations within a macro

rule: macros
level: major
disabled: false
blocked:
  - element: code
    parameters:
      language:
        - json
description: Don't use JSON code blocks; use YAML instead.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.