andexer/wp-laracode
WP Laracode brings Laravel's expressive syntax and tooling to WordPress, helping you organize themes and plugins with familiar conventions, routing, and Blade-style views. It reduces boilerplate and makes WordPress projects feel more like modern Laravel apps while staying within the WordPress ecosys...
andexer/wp-laracode is a Laravel-style framework for building isolated WordPress plugins. With v1.0.50 marked as the first stable release, this is a reasonable baseline for new plugin work.
Minimal setup:
composer global require andexer/wp-laracode
or scaffold a plugin directly:
composer create-project andexer/wp-laracode my-plugin
First steps:
wp-laracode --version
The CLI should display Laravel Framework {plugin_name}/{version}./lang directory.wp-laracode make:controller ExampleController
wp-laracode make:model Example
wp-laracode make:livewire ExamplePanel
Look first at how the package boots Laravel inside WordPress, how service providers are registered, and where WordPress hooks are connected to Laravel controllers/components. That bridge is the key integration point for day-to-day development.
Treat the plugin as a small Laravel application embedded inside WordPress:
make:controller, make:model, make:livewire, and related generators for boilerplate, then keep business logic in application classes rather than in WordPress hook callbacks.get_option, update_option, custom post types, shortcodes, and REST endpoints behind plugin services so the Laravel side remains testable.create-project for new plugins and global CLI for existing plugins: composer create-project is best for a clean plugin baseline; the global binary is useful for adding classes/components inside an existing plugin./lang directory: v1.0.50 standardizes this to Laravel 10+ conventions. Update any custom loading paths or tooling that assumed an older location.Laravel Framework {plugin_name}/{version} output helps confirm which plugin and framework version is active.A practical first workflow is: scaffold a plugin, create a Livewire component for an admin settings screen, bind it to a WordPress admin menu page, and keep option persistence in a service class resolved through the Laravel container.
PATH: if wp-laracode is not found, check Composer’s global bin directory and shell path configuration before debugging the package itself./lang: if upgrading an existing plugin or custom template, check translation loading, .pot generation, and deployment scripts. A missing translation file is often a path issue rather than a package failure.WP_DEBUG, inspect PHP fatal logs for bridge/autoload failures, and verify the Laravel container/provider boot path. Early-boot failures often present as blank admin pages or plugin activation errors.How can I help you explore Laravel packages today?