I remember reading somewhere that model attributes and relationships are autotracked, but I can’t find any documentation on that. It does however seem to be the case when I change model attributes or relationships in the console without set
. If this is the case, is it safe to change this.set()
references in a model to not use set()
, assuming it is only changing an attribute or relationship reference and not a nested value of an object attribute (i.e. no transform)?
3 Likes
They are implemented as computed properties. For example, attr is here. Computed properties interoperate with tracked properties, which is why you can freely mix them.
As far as I know, you’re safe changing attributes and relationships without set
(since Ember 3.13).
3 Likes