WP Bones is back on Product Hunt: 33 releases since the first launch
On August 5, 2024 WP Bones launched here at 1.5.5: a framework that brings Laravel's habits to WordPress plugins. Two years and 33 releases later (1.6.0 3.0.0), here's what's new
Activation sees its own plugin. Since 1.8.0 the activation hook ran with an empty slug and no version, so the options it aligned were saved to a row with no name. Fixed.
Admin pages check who you are. Pages from config/routes.php and pages/ have no menu entry, so WordPress let any logged-in user open them: the capability key was never read. Now a user without it gets a 403.
WP Bones 2.0.10 is out a safety release for bones, the CLI every WP Bones plugin carries, after I audited it line by line
deploy checks where it deploys. php bones deploy .. used to delete every plugin beside yours, and then yours. Now the plugin, its parents and anything inside it are refused, and an unrelated folder needs --force.
WP Bones 2.0.9 is out a small one, about numbers that had quietly stopped agreeing
bones version keeps its hands off your dependencies. On an npm 6 lockfile (lockfileVersion: 1) it bumped your plugin and the first package in the tree. Now only your plugin's own entry moves.
WP Bones 2.0.8 is out and it started as a community pull request
$this->plugin in your commands. Custom php bones commands that call $this->loadWordPress() now get your plugin instance: its config, its services, everything it registers. Before, the loader looked in the framework's own folder and your plugin never booted.
WP Bones 2.0.7 is out and it's a quiet one that makes every release you ship lighter.
Dev packages stay home. bones deploy used to copy vendor/ exactly as it was on disk so PHPUnit, Brain Monkey and everything a test suite pulls in went into your plugin package. On one of my own plugins that was 31 packages. Now the deploy prunes them in the copy, against your composer.lock, and never touches your working tree. Want them anyway? --keep-dev.
WP Bones gives a WordPress plugin the shape of a modern PHP app: service providers, Blade views, Eloquent models, migrations and a bones CLI that scaffolds, renames and deploys. New since the first launch, in 33 releases: • 3.0: secure defaults, admin-only pages, nonces on forms, migrations once per site • A webpack build for React and TypeScript apps • 14 boilerplates you can open in WordPress Playground • 350 tests on PHP 8.1–8.4. Free and open source (LGPL).