• Resolved simondev

    (@simondev)


    Hi,

    I use your plugin, but i have also made 2 patterns manually.
    And I want to add them to a category that I have called “CustomDesign”.

    What “namespace/title” shall i register the block pattern to ?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author BlockMeister

    (@blockmeister)

    Hi,

    When you register your patterns with register_block_pattern you will have to add your custom category name (slug) to the categories property, e.g.:

    register_block_pattern(
        'your-namespace/your-manual-pattern',
        [
            'categories'    => [
                '<strong>customdesign</strong>',
            ],
            [...]
        ],
    );

    Note: currently custom categories are not namespaced. This might change in a future release!

    Plugin Author BlockMeister

    (@blockmeister)

    The code sample contained some unwanted markup, corrected:

    register_block_pattern(
        'your-namespace/your-manual-pattern',
        [
            'categories'    => [
                'customdesign',
            ],
        ],
    );
Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘namespace/title’ is closed to new replies.