flarum / framework

Simple forum software for building great communities.
http://flarum.org/
6.39k stars 834 forks source link

refactor: unify frontend initializers naming #4003

Closed DavideIadeluca closed 5 months ago

DavideIadeluca commented 5 months ago

Fixes #0000

Changes proposed in this pull request: Use consistent naming for frontend initializers (and slightly change syntax), as the current best practice seems to be acme-foobar. Some bundled extensions were still initialized like this: acme/foobar or foobar.

Reviewers should focus on: Seems like no bundled extension does any check in the frontend if another extension is initialized, for example:

if (app.initializers.has('flarum-tags')) {
    ...
}

So, as far as I can tell, the changes introduced in the PR should work standalone. But please double-check that I've not missed anything else for this to work out of the box (I have not yet setup 2.x for local development..)

Extension developers need to refactor their frontend initializer checks when upgrading their extensions for 2.x, so this must be included in the upgrade guide and potentially also noted as a breaking change.

Screenshot

QA

Necessity

Confirmed

Required changes: