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
Update the assignment of this.args
to reflect the arg proxy
#201
Update the assignment of this.args
to reflect the arg proxy
#201
Conversation
b012aae
to
ab4a819
Compare
You should be able to use |
Looks like the CI failure is a bunch of typescript errors when ran against canary builds of ember-source. |
@rwjblue I wanted to be a bit more sure before we pinned it here, it'll be annoying if we release a version and it breaks later, but I can also add conditional code if you prefer. Definitely can put the test in the conditional at least. As for the test failures, there's a legitimate one in there, it's caused by the fact that CPs can't work with the args proxy yet. Fix is here: emberjs/ember.js#18217 |
dd400ae
to
4956620
Compare
packages/@glimmer/component/test/ember/integration/components/glimmer-component-test.js
Outdated
Show resolved
Hide resolved
The refactor to use a proxy for tracking individual updates to args requires us to make some changes here in how we assign arguments. Also adds the `updateHook` option to capabilities. This solution should be compatible with Ember pre and post enabling the tracked canary flag, but can be made better with ember-compatibility-helpers once we have a version of Ember to target.
4956620
to
82f4863
Compare
Great work here! There is currently an odd proxy-related error that occurs on ember canary (or 3.13.x), and a few of us believe that this will fix the error. See this example repo which highlights the problem: https://github.com/justinross/e-octane-bug |
this.args
to reflect the arg proxy
Thanks for this fix! We had the same problem demonstrated in the repo above:
And as discussed here updating I'm wondering what it is about the canary that makes it work. Are there changes in |
There were changes in |
Per [this PR](glimmerjs/glimmer.js#201), this is meant to fix the bug but it doesn't with the latest `ember-source`
It looks like the relevant fix in Or I'm misunderstanding what this was meant to fix. I put together a a reproduction here - should that work? |
Discussed on discord and fixed by @pzuraq in ember.js#18274 - thanks! |
The refactor to use a proxy for tracking individual updates to args
requires us to make some changes here in how we assign arguments. Also
adds the
updateHook
option to capabilities. This solution should becompatible with Ember pre and post enabling the tracked canary flag,
but can be made better with ember-compatibility-helpers once we have
a version of Ember to target.