Conversation
Estimated Asset SizesDiff Details
|
|
Edit: solved Currently failing in Safari and Firefox 🤔 This repros locally |
| if (options.eval) { | ||
| return options.eval; | ||
| } else { | ||
| const scope = options.scope?.(); |
There was a problem hiding this comment.
@ef4 this is why I think we need to change the compiled JSON format to allow objects for scope.
Because the runtime compiler now eagerly consumes all args upon setting up the component to render.
This is incorrect, because args should not be consumed until rendered.
357a531 to
afde876
Compare
afde876 to
8f84f97
Compare
| return evaluator; | ||
| } | ||
|
|
||
| scope = Object.assign({}, keywords, scope); |
There was a problem hiding this comment.
these need to be mixed in here when using "explicit scope"
There was a problem hiding this comment.
a demo of what happens when we remove: #21073
not ok 14 Chrome 144.0 - [5 ms] - [integration] jit :: keyword modifier: on (runtime): explicit scope
---
stack: >
ReferenceError: on is not defined
| return component; | ||
| } | ||
|
|
||
| Object.assign(template, keywords); |
There was a problem hiding this comment.
we have to have a known reference for "implicit scope" to use -- becauseu we can't change imports.
the only alternative to this is maybe having a static list of things on globalThis, but then we can't have multiple ember versions loaded at once
Alternate implementation to #21055
https://rfcs.emberjs.com/id/0997-make-on-built-in
We already have tests for importing on.
This PR lays the foundation for all future modifiers/helpers being used as "keywords"
fn(RFC #998),hash(RFC #999),array(RFC #1000)and,or,not- RFC #562lt,lte,gt,gte- RFC #561eq,neq- RFC #560element- RFC #389(which are all going to be more tests than implementation (we're set up for each new utility to basically be one line each))
Also in this PR is an internal upgrade for our smoke-test app(s), because I was hitting the error where
emberAppSatisfieswas missing due to out of date deps.