✅ The "extends": "plugin:ember/recommended"
property in a configuration file enables this rule.
This rule aims to enforce Glimmer components instead of classic ones. We should migrate to Glimmer components because they have few advantages:
- Simpler API
- No wrapper element
- Namespaced Arguments
- Less lifecycle hooks
- Stateless Template-Only Components
- Unidirectional Dataflow
With that simpler API we could improve the DX and also lower the entry level for Ember.
If you want to migrate to Glimmer components this rule can help find the classic components that you need to migrate.
Examples of incorrect code for this rule:
import Component from '@ember/component';
Examples of correct code for this rule:
import Component from '@glimmer/component';
- Ember 3.13 Release Notes (minimum Ember version needed to use Glimmer components)
- Ember Glimmer Components RFC
- Ember Octane Release Plan
- Glimmer Components Explained