|
1 | 1 | --- |
2 | | -file_type: "instructions" |
3 | | -title: "WordPress Block Development Guidelines" |
4 | | -description: "Comprehensive guide for developing WordPress blocks using modern patterns, block.json-first approach, and WordPress best practices" |
5 | | -applyTo: "**/*.{js,jsx,ts,tsx,php}" |
6 | | -version: "v3.0" |
7 | | -last_updated: "2025-12-10" |
8 | | -owners: ["LightSpeedWP Team"] |
9 | | -tags: ["wordpress", "blocks", "gutenberg", "plugin", "development", "react"] |
10 | | -domain: "wp-core" |
11 | | -stability: "stable" |
| 2 | +file_type: instructions |
| 3 | +title: WordPress Block Development Guidelines |
| 4 | +description: >- |
| 5 | + Comprehensive guide for developing WordPress blocks using modern patterns, |
| 6 | + block.json-first approach, and WordPress best practices |
| 7 | +applyTo: '**/*.{js,jsx,ts,tsx,php}' |
| 8 | +version: v3.0 |
| 9 | +last_updated: '2025-12-10' |
| 10 | +owners: |
| 11 | + - LightSpeedWP Team |
| 12 | +tags: |
| 13 | + - wordpress |
| 14 | + - blocks |
| 15 | + - gutenberg |
| 16 | + - plugin |
| 17 | + - development |
| 18 | + - react |
| 19 | +domain: wp-core |
| 20 | +stability: stable |
| 21 | +references: |
| 22 | + - ../custom-instructions.md |
12 | 23 | --- |
13 | 24 |
|
14 | 25 | > ⚠️ **Scope Notice**: These instructions are intended for **WordPress block plugin repositories** within the `lightspeedwp` GitHub organisation. They should **not** be applied to the `lightspeedwp/.github` community health repository, as that repository does not contain WordPress plugin code. |
@@ -735,16 +746,6 @@ See [security.instructions.md](./security.instructions.md) for comprehensive sec |
735 | 746 |
|
736 | 747 | --- |
737 | 748 |
|
738 | | -## References |
739 | | - |
740 | | -- [Block Editor Handbook](https://developer.wordpress.org/block-editor/) |
741 | | -- [@wordpress/scripts](https://developer.wordpress.org/block-editor/reference-guides/packages/packages-scripts/) |
742 | | -- [Block API Reference](https://developer.wordpress.org/block-editor/reference-guides/block-api/) |
743 | | -- [Block Supports](https://developer.wordpress.org/block-editor/reference-guides/block-api/block-supports/) |
744 | | -- [WordPress Coding Standards](https://developer.wordpress.org/coding-standards/) |
745 | | - |
746 | | ---- |
747 | | - |
748 | 749 | ## ⚠️ Important Reminders |
749 | 750 |
|
750 | 751 | - **Never edit built files directly** — Always keep source and build output separate |
@@ -805,3 +806,11 @@ import { useState, useEffect, useCallback, useMemo } from '@wordpress/element'; |
805 | 806 | - For dynamic blocks, hit render endpoints or E2E tests to confirm server output. |
806 | 807 |
|
807 | 808 | --- |
| 809 | + |
| 810 | +## See Also |
| 811 | + |
| 812 | +- [Block Editor Handbook](https://developer.wordpress.org/block-editor/) |
| 813 | +- [@wordpress/scripts](https://developer.wordpress.org/block-editor/reference-guides/packages/packages-scripts/) |
| 814 | +- [Block API Reference](https://developer.wordpress.org/block-editor/reference-guides/block-api/) |
| 815 | +- [Block Supports](https://developer.wordpress.org/block-editor/reference-guides/block-api/block-supports/) |
| 816 | +- [WordPress Coding Standards](https://developer.wordpress.org/coding-standards/) |
0 commit comments