> For the complete documentation index, see [llms.txt](https://whoisandywhite.gitbook.io/porterwp/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://whoisandywhite.gitbook.io/porterwp/documentation/blocks-json.md).

# Blocks Json

Manages **block styles, patterns and block‑level housekeeping**.

```jsonc
{
  "version": "1.0.2",
  "blocks": {
    "settings": {
      "folders": [
        "/components",
        "/layouts",
        "/query-blocks"
      ],
      "blockCategories": ["structure", "marketing"]
    },

    "styles": {
      "core/button": {
        "Download": {            // label shown in UI
          "inherit": ["core/link", "Download"], // OPTIONAL – re‑uses CSS from another style
          "label": false                        // hide label chip in list view
        },
        "External": {}
      },
      "acf/filters": {
        "Horizontal": {}
      }
    },

    "unregisterStyles": {
      "core/table": ["stripes", "regular"]
    },

    "patterns": {
      "register": {
        "my/event-template": { "title": "Event Template" },
        "my/hero":         { "title": "Hero Section" }
      },
      "categories": ["My Patterns", "Synced"],
      "unregisterCategories": ["core"]
    },

    "unregisterBlocks": ["core/spacer"],
    "dequeueStyles": ["wp-block-navigation", "wp-block-columns"]
  }
}
```

## Keys

| Path                                   | Purpose                                                                                                                                                                                                                                                       |
| -------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `version`                              | Cache‑buster for PorterWP.                                                                                                                                                                                                                                    |
| `blocks.settings.folders`              | Additional directories Porter scans when `make.sh` scaffolds a block.                                                                                                                                                                                         |
| `blocks.settings.blockCategories`      | Custom block categories added to the inserter.                                                                                                                                                                                                                |
| `blocks.styles`                        | **Block‑>Style‑>Options**. Valid options:• `inherit` = `[block, style]` to copy another style’s CSS.• `label` = `false` hides the style name in the UI (useful for decorative styles).• Any other key is passed through as an inline setting on registration. |
| `blocks.unregisterStyles`              | Core block styles to unregister.                                                                                                                                                                                                                              |
| `blocks.patterns.register`             | Register block patterns (`title` is mandatory, `description` & `categories` optional).                                                                                                                                                                        |
| `blocks.patterns.categories`           | Add custom pattern categories.                                                                                                                                                                                                                                |
| `blocks.patterns.unregisterCategories` | Remove pattern categories.                                                                                                                                                                                                                                    |
| `blocks.unregisterBlocks`              | Prevent specific blocks appearing in the inserter.                                                                                                                                                                                                            |
| `blocks.dequeueStyles`                 | Stylesheets to dequeue if you roll your own CSS.                                                                                                                                                                                                              |

***

### Example: silent utility style

```jsonc
"styles": {
  "core/group": {
    "Overflow Hidden": { "label": false }
  }
}
```

The style appears in the **Styles** sidebar but carries no visible label on the block. Handy for utility wrappers.

***

⇐ [Back to Config Index](/porterwp/documentation/configuration-files.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://whoisandywhite.gitbook.io/porterwp/documentation/blocks-json.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
