- Generated plugins and modules now call
$this->attachEventHandlers()
directly frominit()
, and clarify whenonInit()
should be used.
- Generated field types, utilities, and widget types now provide default icons.
- Fixed an error that occurred when generating a utility. (#34)
- Craft Generator now requires Craft 5.
- Renamed
craft\wpimport\Command\EVENT_REGISTER_GENERATOR_TYPES
toEVENT_REGISTER_GENERATORS
.
- Generated plugins and modules now call
$this->attachEventHandlers()
directly frominit()
, and clarify whenonInit()
should be used.
- Added the behavior generator. (#27)
- Generator now prompts for new modules’ names. (#28)
- Added the
--with-strict-types
option. (#29) - Fixed issues with the default
getTriggerHtml()
method output for generated element actions. (#30)
- Fixed a double-backslash bug.
- Added
craft\wpimport\BaseGenerator::messageTwig()
. (#25) - The plugin generator now ensures that the project’s
composer.json
file hasminimum-stability: dev
andprefer-stable: true
set. (#22) - Fixed a bug where the Service generator was suggesting adding a
config()
method which defined the service config, even when the target was a module. (#24)
- Improved the validation error for private plugins’ handle prompts, for handles that don’t begin with an underscore. (#18)
- The plugin generator’s “Minimum Craft CMS version” prompt now defaults to the initial minor release of the current Craft version (e.g.
4.4.0
rather than4.4.11
), if running a stable release of Craft 4.4 or later. - The plugin generator now warns against using non-unique plugin handles.
- Generated plugins’ and modules’
init()
methods now have avoid
return type. (#20) - Fixed a bug where it was possible to enter invalid UTF-8 characters into the plugin generator prompts, causing an exception when writing the
composer.json
file. - Craft CMS 4.4.11+ is now required.
- Generated plugins now include a “Create Release” GitHub action, which will create a new GitHub Release whenever the Craft Plugin Store is notified of a new version tag.
- Fixed a PHP error that occurred when generating a private plugin, if a different minimum Craft version was entered.
- Fixed a bug where generated elements had a PHP syntax error. (#15)
- Added support for generating private plugins (requires Craft 4.4.0-beta.1 or later).
- Fixed a bug where generated modules weren’t defining a root alias for themselves, leading to an exception getting thrown when running Craft’s
help
command. (#11)
- Fixed a bug where element condition and query classes weren’t getting imported for the element class. (#13)
- Fixed a bug where
ecs.php
class imports were missing characters. (#13)
- Added the GraphQL directive generator (
gql-directive
). - Fixed a bug where plugins’
composer.json
would include invalidrequire-dev
dependencies if ECS or PHPStan weren’t used. (#9)
- Added the Twig Extension generator (
twig-extension
). (#8) - Added support for generating components within arbitrary source paths, via a new
--path
option. - Improved the web controller scaffolding.
- Fixed an error that could occur when generating a component for a plugin or module, if the plugin/module class didn’t have an
init()
orattachEventHandlers()
method.
- Plugins’ and modules’
attachEventHandlers()
methods now include a comment pointing to the Events documentation.
- The plugin generator now includes
craft-
in the default suggested Composer package name. (#5) - The module generator now suggests a default root namespace based on root location, if it’s not already autoloadable. (#2)
- Fixed a bug where the plugin generator didn’t allow Composer package names that contained numbers. (#4)
- The service generator will now modify plugins’
config()
method even if it is defined by a separate trait or base class, so long as it lives within the plugin’s root path. - Added
craft\wpimport\BaseGenerator::findModuleMethod()
. - Fixed an error that occurred when generating a plugin, if a custom minimum Craft CMS version was entered. (#1)
- Fixed an error that could occur if a plugin or module’s base namespace contained double-backslashes. (#3)
- Fixed a bug where new modules weren’t being added to
config/app.php
automatically if nomodules
key existed yet.
- Initial release