A Generator For the WordPress Plugin Boilerplate

The WordPress Plugin Boilerplate is a popular tool for getting started with plugin development. Many top-notch WordPress developers have contributed to the boilerplate and the 2.6.0 release of the plugin provided a major update.

Using the plugin boilerplate as a starting place for plugin creation, a developer can quickly whip up a plugin in a matter of minutes. But what if you could do that even faster? Brad Vincent, author of the Themergency.com WordPress development blog, created a generator for the WordPress Plugin Boilerplate.

Using code from the grunt-wp-plugin by 10up, Vincent was able to set up a grunt-init template that generates a plugin from the boilerplate in about 30 seconds flat.

example-command-line

The WordPress Plugin Boilerplate Generator github repo provides instructions for installing grunt-init and using the command line to create your new plugin.

newly generated plugin

The generator includes all the relevant plugin author information. It also automatically renames all the files correctly and replaces all the necessary variables within the files. The end result is your newly generated plugin, customized and ready for you to start building.

6 Comments


  1. The boilerplate is great and I’m happy that people are now using proven skeletons without having to reinvent the wheel.

    Tom might correct me if I’m wrong, but I think that DX Plugin Base started a bit before that and we’ve been using that in my courses and classes teaching new WordPress developers; several plugins in WordPress.org have also started with that base (and it’s also open to any contributions).

    Report


  2. Hey Sarah – thanks for posting about the boilerplate generator – I hope others find it useful. I am working with Tom McFarlin and Alex Mansfield on something at the moment that will make this whole process even easier…

    Report


Comments are closed.