-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
[BUGFIX release] loosemode interop not working with renderComponent #20994
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
[BUGFIX release] loosemode interop not working with renderComponent #20994
Conversation
Estimated Asset SizesDiff --- main/out.txt 2025-10-13 19:57:14.000000000 +0000
+++ pr/./pr-18722209612/out.txt 2025-10-22 15:58:24.000000000 +0000
@@ -1,41 +1,41 @@
╔═══════╤═══════════╤═══════════╗
║ │ Min │ Gzip ║
╟───────┼───────────┼───────────╢
-║ Total │ 417.63 KB │ 231.54 KB ║
+║ Total │ 417.63 KB │ 231.59 KB ║
╚═══════╧═══════════╧═══════════╝
-╔══════════════════════╤═══════════╤═══════════╗
-║ @ember/* │ Min │ Gzip ║
-╟──────────────────────┼───────────┼───────────╢
-║ Total │ 238.38 KB │ 146.55 KB ║
-╟──────────────────────┼───────────┼───────────╢
-║ -internals │ 34.55 KB │ 24.85 KB ║
-║ application │ 12.71 KB │ 7.66 KB ║
-║ array │ 12.66 KB │ 7.32 KB ║
-║ canary-features │ 304 B │ 419 B ║
-║ component │ 1.07 KB │ 963 B ║
-║ controller │ 1.8 KB │ 1.36 KB ║
-║ debug │ 11.4 KB │ 7.92 KB ║
-║ deprecated-features │ 31 B │ 77 B ║
-║ destroyable │ 561 B │ 383 B ║
-║ enumerable │ 259 B │ 387 B ║
-║ helper │ 823 B │ 609 B ║
-║ instrumentation │ 2.43 KB │ 1.78 KB ║
-║ modifier │ 669 B │ 605 B ║
-║ object │ 33.78 KB │ 20.79 KB ║
-║ owner │ 159 B │ 178 B ║
-║ renderer │ 406 B │ 349 B ║
-║ routing │ 58.08 KB │ 33.44 KB ║
-║ runloop │ 2.2 KB │ 1.33 KB ║
-║ service │ 859 B │ 741 B ║
-║ template │ 430 B │ 357 B ║
-║ template-compilation │ 429 B │ 366 B ║
-║ template-compiler │ 57.91 KB │ 30.4 KB ║
-║ template-factory │ 94 B │ 160 B ║
-║ test │ 923 B │ 627 B ║
-║ utils │ 3.93 KB │ 3.5 KB ║
-║ version │ 55 B │ 131 B ║
-╚══════════════════════╧═══════════╧═══════════╝
+╔══════════════════════╤═══════════╤══════════╗
+║ @ember/* │ Min │ Gzip ║
+╟──────────────────────┼───────────┼──────────╢
+║ Total │ 238.38 KB │ 146.6 KB ║
+╟──────────────────────┼───────────┼──────────╢
+║ -internals │ 34.55 KB │ 24.85 KB ║
+║ application │ 12.71 KB │ 7.63 KB ║
+║ array │ 12.66 KB │ 7.32 KB ║
+║ canary-features │ 304 B │ 419 B ║
+║ component │ 1.07 KB │ 1018 B ║
+║ controller │ 1.8 KB │ 1.36 KB ║
+║ debug │ 11.4 KB │ 7.92 KB ║
+║ deprecated-features │ 31 B │ 77 B ║
+║ destroyable │ 561 B │ 383 B ║
+║ enumerable │ 259 B │ 387 B ║
+║ helper │ 823 B │ 610 B ║
+║ instrumentation │ 2.43 KB │ 1.78 KB ║
+║ modifier │ 669 B │ 601 B ║
+║ object │ 33.78 KB │ 20.79 KB ║
+║ owner │ 159 B │ 178 B ║
+║ renderer │ 406 B │ 346 B ║
+║ routing │ 58.08 KB │ 33.45 KB ║
+║ runloop │ 2.2 KB │ 1.33 KB ║
+║ service │ 859 B │ 741 B ║
+║ template │ 430 B │ 388 B ║
+║ template-compilation │ 429 B │ 366 B ║
+║ template-compiler │ 57.91 KB │ 30.4 KB ║
+║ template-factory │ 94 B │ 160 B ║
+║ test │ 923 B │ 627 B ║
+║ utils │ 3.93 KB │ 3.5 KB ║
+║ version │ 55 B │ 131 B ║
+╚══════════════════════╧═══════════╧══════════╝
╔═════════════════╤═══════════╤══════════╗
║ @glimmer/* │ Min │ Gzip ║Details
|
packages/@ember/-internals/glimmer/tests/integration/components/render-component-test.ts
Outdated
Show resolved
Hide resolved
Fix for the failing test -- turns out we don't need a StrictResolver Also add the reverse test so we don't accidentally enable loosemode in strict components.
4c666da to
ec579cf
Compare
|
there seems to be also something else going on - in the original repro, the corrected code now passes the first call to renderComponent, but the second one, even if it's the same render function call, explodes again with |
|
yeah, that is indeed a separate issue -- worthy of a separate PR and repro -- and one that I haven't been able to repro myself consistently. Lets chat in discord about how to re-create that error |
We don't need a
StrictResolver, because there is no resolving in strict mode.The resolver that is constructed for the strict renderer is what is used for the whole of that rendering tree.
When a strict-mode component encounters something not in the scope bag, it throws a compile-time syntax error -- so resolution never occurs.
Big thanks to @vlascik for reporting and providing a repro