Merged
Conversation
fe2f929 to
c0f5a79
Compare
| registerPlugin('ast', TransformOldBindingSyntax); | ||
| registerPlugin('ast', TransformOldClassBindingSyntax); | ||
| registerPlugin('ast', TransformItemClass); | ||
| registerPlugin('ast', TransformClosureComponentAttrsIntoMut); |
Contributor
There was a problem hiding this comment.
why not just guard this one? some of the others are needed to pass tests
Contributor
|
☔ The latest upstream changes (presumably #13319) made this pull request unmergeable. Please resolve the merge conflicts. |
added 3 commits
April 27, 2016 18:25
This makes `{{component "foo-bar"}}` more or less the same as `{{foo-bar}}`.
It also works for passed-in attrs like `{{component @stuff}}` where
`@stuff` is static on the invocation side `{{x-outside stuff="foo-bar"}}`.
Previously, doing a `Ember.set(foo, 'bar.baz.bat', ...)` incorrectly marks both the "foo", "bar" and "baz" objects as dirty. This fixes the problem and only mark "bat" as dirty, i.e. making this the same as doing `Ember.set(Ember.get(foo, 'bar.baz'), 'bat', ...)`.
42c0059 to
70ed331
Compare
added 4 commits
April 27, 2016 19:03
Even if the source and path reference has not changed, the content could still have changed, similar to how `PropertyReference` works.
This is causing issues because we have not implemented the `mut` helper in `ember-glimmer` (among other things).
We previously marked them as `volatile` with a FIXME because we need to
support proxies. This reduces the scope and only mark conditionals with
proxies as volatile (we can still do better than that by making proxy
objects have a special tag that combines its own `DirtyableTag` with the
tag from its `content`, but it's pretty low priority at the moment).
The refactor also added a new optimizations: by reusing the same code
across the syntax (`{{#if}}`) and the helper (`{{if}}`) versions, the
inline conditional helpers now also participate in the same const
optimization, i.e. `{{if true foo bar}}` will be optimized into `{{foo}}`,
so as `{{if @stuff foo bar}}` if `@stuff` is static.
TODO: fix tests that uses fake proxies, see comment in `references.js`
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Glimmer compiler needs wire-format and references
Const reference optimization for dynamic component
This optimizes
{{component "foo-bar"}}into the same thing as{{foo-bar}}in the updating program. It also works for passed-in attrs like{{component @stuff}}where@stuffis static on the invocation side{{x-outside stuff="foo-bar"}}.Correctly dirty
Ember.set(foo, 'bar.baz.bat', ...)Previously, doing a
Ember.set(foo, 'bar.baz.bat', ...)incorrectly marks both the "foo", "bar" and "baz" objects as dirty. This fixes the problem and only mark "bat" as dirty, i.e. making this the same as doingEmber.set(Ember.get(foo, 'bar.baz'), 'bat', ...).Disable AST transforms on Glimmer for now
This is causing issues because we have not implemented the
muthelper inember-glimmer(among other things). We can selectively re-enable stuff we still need (and works) as we go.Make conditional helpers/references not volatile
We previously marked them as
volatilewith a FIXME because we need to support proxies. This reduces the scope and only mark conditionals with proxies as volatile (we can still do better than that by making proxy objects have a special tag that combines its ownDirtyableTagwith the tag from itscontent, but it's pretty low priority at the moment).The refactor also added a new optimizations: by reusing the same code across the syntax (
{{#if}}) and the helper ({{if}}) versions, the inline conditional helpers now also participate in the same const optimization, i.e.{{if true foo bar}}will be optimized into{{foo}}in the updating program, so as{{if @stuff foo bar}}if@stuffis static.TODO: fix tests that uses fake proxies, see comment in
references.js(cc @chadhietala)cc @krisselden