ember/no-proxies
October 27, 2022 ยท View on GitHub
You may want to disallow the use of Ember proxy objects (ObjectProxy, ArrayProxy) in your application for a number of reasons:
- Proxies are relatively rare compared to direct property access on objects.
- In part due to their rarity, proxies are not as widely understood.
- Proxies can add unnecessary complexity.
- Proxies do not support ES5 getters which were introduced in Ember 3.1 (they still require using
this.get())
Note: this rule is not in the recommended configuration because there are legitimate usages of proxies.
Rule Details
This rule disallows using Ember proxy objects (ObjectProxy, ArrayProxy).
Examples
Examples of incorrect code for this rule:
import ObjectProxy from '@ember/object/proxy';
import ArrayProxy from '@ember/array/proxy';
Related Rules
- no-get which may need to be disabled for
this.get()usages in proxy objects
References
- ObjectProxy spec
- ArrayProxy spec