mirror of
https://github.com/discourse/discourse.git
synced 2025-02-10 13:24:55 +00:00
In the future we'll be looking at things like tree-shaking and code-splitting. Using 'magic strings' to resolve components is not compatible with those techniques. It makes sense to switch to a more modern pattern now, before the new user-tab API is used too widely. This commit is backwards-compatible. API consumers which pass a string will see a deprecation message asking them to pass a component class instead. This commit also turns some unneeded getters into simple class properties (no need to use a getter when it just returns a constant).