You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Default imports for some modules, such as npm:[email protected]/parser-html, behave differently when statically imported on the client side vs server side.
Repro:
Bootstrap app with deno run -A -r https://fresh.deno.dev
Replace content of islands/Counter.tsx with the following:
Open server URL and observe output in browser console:
ok (dynamic)
assert.ts:21 Uncaught AssertionError: No default prop! (static)
at assert (assert.ts:21:11)
at Counter.tsx:9:1
On the server, both staticMod and dynamicMod are module objects with default props; however, on the client, staticMod is itself the default export (i.e. it doesn't have a default prop of its own).
The text was updated successfully, but these errors were encountered:
Default imports for some modules, such as
npm:[email protected]/parser-html
, behave differently when statically imported on the client side vs server side.Repro:
Bootstrap app with
deno run -A -r https://fresh.deno.dev
Replace content of
islands/Counter.tsx
with the following:Observe output in CLI console:
Open server URL and observe output in browser console:
On the server, both
staticMod
anddynamicMod
are module objects withdefault
props; however, on the client,staticMod
is itself thedefault
export (i.e. it doesn't have adefault
prop of its own).The text was updated successfully, but these errors were encountered: