2

When working on a plugin recently, I decided to add a CP section:

composer.json

{
    ...
    "extra":
        ...
        "hasCpSection": true
    ...
}

The only way that I was able to have this change reflected in Craft was to uninstall/reinstall the plugin. Is there an alternate way (e.g. CLI) to do so?

2

You can uninstall the plugin via CLI but I guess that's not really what you are after. The only other way is to change the auto generated config file in vendor/craftcms/plugins.php and change the parameter for your plugin there. But you can't ever change this attribute for others that downloaded your plugin remotely without doing things you should not do.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.