Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deprecate implicit this property lookup fallback #19371

Merged
merged 1 commit into from
Feb 2, 2021

Conversation

rwjblue
Copy link
Member

@rwjblue rwjblue commented Feb 2, 2021

Lands the deprecation proposed in emberjs/rfcs#308:

The no-implicit-this template linting rule has been enabled for Ember applications by default since around Ember 3.16 (included in the octane preset).

This PR will take that a step further and issue a deprecation for templates that are still using {{foo}} to mean {{this.foo}}.

Note: It does provide for an easy way to temporarily disable the deprecation messages (e.g. to reduce console output to hone in on other issues). This is intended for sporadic usage while debugging not as a way to mitigate the deprecation (the fallback behavior will be removed in 4.0.0).

Copy link
Contributor

@pzuraq pzuraq left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks good, didn't realize that class bindings could have this in them. The only thing is to add the URL for the deprecation guide.

Lands the deprecation proposed in
[emberjs/rfcs#308](https://github.com/emberjs/rfcs/blob/master/text/0308-deprecate-property-lookup-fallback.md):

The
[no-implicit-this](https://github.com/ember-template-lint/ember-template-lint/blob/master/docs/rule/no-implicit-this.md)
template linting rule has been enabled for Ember applications by default
since around Ember 3.16 (included in the `octane` preset).

This PR will take that a step further and issue a deprecation for
templates that are still using `{{foo}}` to mean `{{this.foo}}`.

Note: It does provide for an easy way to temporarily disable the
deprecation messages (e.g. to reduce console output to hone in on other
issues). This is intended for sporadic usage while debugging **not** as
a way to mitigate the deprecation (the fallback behavior will be
removed in 4.0.0).
@rwjblue rwjblue force-pushed the deprecate-this-fallback branch from c793a41 to 7b628fc Compare February 2, 2021 17:12
@rwjblue rwjblue merged commit 77d8f7b into master Feb 2, 2021
@rwjblue rwjblue deleted the deprecate-this-fallback branch February 2, 2021 18:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants