-
Notifications
You must be signed in to change notification settings - Fork 0
Getting Started
Fast path (recommended) — scaffold + personalize in one step:
composer create-project wp-plugin-matrix/starter my-awesome-pluginThe post-create-project-cmd runs the Personalizer automatically: it prompts for the plugin name,
namespace, and vendor, rewrites every identity token (WPPluginMatrix namespace, wp-plugin-matrix
slug/text-domain, WP_PLUGIN_MATRIX_* constants, main-file name, composer.json name), then deletes
itself. Skip the prompts non-interactively:
composer create-project wp-plugin-matrix/starter my-awesome-plugin -- "My Awesome Plugin" MyAwesomePlugin acmeManual path — if you cloned the repo directly:
php rename-plugin.php "My Awesome Plugin" # add --dry-run to preview
composer install && npm install
npm run build
wp plugin activate my-awesome-pluginActivation runs the Lifecycle: it applies pending migrations (creating tables), seeds the demo, registers capabilities, and schedules cron. You'll land on a working plugin with a Tasks admin page (a full CRUD demo).
wp matrix:make:resource BookThis generates a Book Model, a migration, a controller, a BooksListPage, and the routes — wired and
ready. Re-activate (or run the migration) and a Books CRUD page appears. See CLI Generators.
Prefer to hand-write it? See Models & Validation and Admin & List Pages.
When you're ready to start clean:
wp matrix:clean --dry-run # preview
wp matrix:clean # remove the Task demo → blank starterSee Demo & Reset.
composer install # PHP deps + autoloader
npm run dev | build # Vite dev / production assets
./vendor/bin/pest # PHP unit tests
wp matrix:make:<thing> [--dry-run] # scaffold model/migration/controller/listpage/adminpage/route/resource/types
wp matrix:clean [--dry-run] # strip the demoWP Plugin Matrix · GPL-2.0-or-later · source · pages are generated from docs/wiki/ — edit there, not in the wiki UI.
Seams
Tooling