You've already forked wp-bootstrap
feat: add wp_bootstrap_should_render_template filter for plugin decoupling (v1.0.4)
Allows plugins and child themes to prevent the theme's TemplateController from rendering specific requests, enabling clean separation of concerns. Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -84,7 +84,7 @@ The theme uses a dual-rendering approach:
|
||||
- **Site Editor (admin):** FSE block templates in `templates/` and `parts/` for visual editing
|
||||
- **Frontend (public):** Twig templates in `views/` render Bootstrap 5 HTML via the `template_redirect` hook
|
||||
|
||||
The `TemplateController` intercepts frontend requests and renders the appropriate Twig template with data gathered by `ContextBuilder`. FSE templates remain untouched for the WordPress admin editor.
|
||||
The `TemplateController` intercepts frontend requests and renders the appropriate Twig template with data gathered by `ContextBuilder`. Plugins can hook into the `wp_bootstrap_should_render_template` filter to prevent rendering for specific requests (e.g., when a plugin handles its own custom post types). FSE templates remain untouched for the WordPress admin editor.
|
||||
|
||||
### Style Variation Bridge
|
||||
|
||||
|
||||
Reference in New Issue
Block a user