Schema
Last modified:
To improve development with autocomplete and validation in your IDE, Blockstudio introduces its own schema:
The Blockstudio schema is an (always up-to-date) copy of the WordPress core block.json schema with two differences:
- Attributes are removed (see how to register custom attributes for more information)
- Additional blockstudio property that houses all plugin features like field schemas without interfering with potential future core properties
Add to JSON
Simply add a $schema
key with a value of
https://app.blockstudio.dev/schema to your block.json and your IDE should
start to give you hints about Blockstudio specific properties.
{
"$schema": "https://app.blockstudio.dev/schema",
"apiVersion": 2,
"name": "blockstudio/native",
"title": "Native Block",
"category": "text",
"icon": "star-filled",
"description": "Native Blockstudio block.",
"keywords": [
"block",
"native"
],
"version": "1.0.0",
"textdomain": "blockstudio",
"blockstudio": true
}
