Caution: This plugin is still alpha. There might be breaking changes.
However the only change that is planned until beta release that may break anything is the restructuring of the default templates.
They are used to inherit from in your theme templates. Just keep that in mind and check the changes on the default templates you inherit from before you update until beta is released.
Beta is going to be released very soon.
Feedback and feature requests are welcome!
Woodlets is a WordPress plugin that makes theme development more productive and fun.
The main features are:
- Heavily Twig based theme development
- Create widgets with a single Twig-Template file
- Multi column page layouts
- Custom page template fields with data inheritance
- Simple way to add controls to the theme customizer
- Compatible with native WordPress widgets
Installation via composer is recommended. But there is also a bundled version that can be installed manually, since using composer is not that common in the WordPress world.
You need to to set installer path for wordpress-plugin
type.
{
"extra": {
"installer-paths": {
"vendor/WordPress/wp-content/plugins/{$name}/": [
"type:wordpress-plugin"
]
}
}
}
Install Woodlets via composer:
composer require neochic/woodlets
Check "Woodlets Seed"-Theme composer.json for a working example.
- Go to releases page and download the latest bundled release.
- Extract the zip archive to your WordPress plugins directory (usually "wp-content/plugins/").
- Activate the plugin on the plugins page of your WordPress installation.
-
Be sure the Woodlets plugin is installed and activated.
-
Create a new theme (as the WordPress documentation says it should at least contain
style.css
andindex.php
) -
Put the following lines into your
index.php
:<?php do_action('neochic_woodlets_render_template');
The action
neochic_woodlets_render_template
initializes the template rendering. -
Activate your new theme.
-
Create your first page template with at least one column. Learn how to create your own page templates.
-
Create your first Woodlets widget. Learn how to create custom widgets.
-
Add your new widget to the allowed widgets configuration of your page template column.
-
Create or edit a page and use your new page layout to test your widget in backend and frontend.
For the creation of new Woodlets themes you may download the "Woodlets Seed"-Theme instead of starting from scratch. It might also be a good idea to take a look at the "Woodlets Example"-Theme.