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
I thought we might be able to get away with this, since live bindings aren't likely to be an issue during SSR, but I was wrong — working on #229, I discovered that in order to make paths configurable at runtime (so that svelte-kit start continues to work with a build that defaults to the paths declared in svelte.config.js), we need to have live bindings. Otherwise
import{base,assets}from'$app/path';
will yield a pair of undefined paths.
I think I know how to implement it (replace all references to named imported bindings like foo with __import1.foo, replace all exports.foo = foo with Object.defineProperty(exports, 'foo', { get: () => foo }), it's just a bit of a nuisance
The text was updated successfully, but these errors were encountered:
I thought we might be able to get away with this, since live bindings aren't likely to be an issue during SSR, but I was wrong — working on #229, I discovered that in order to make paths configurable at runtime (so that
svelte-kit start
continues to work with a build that defaults to the paths declared in svelte.config.js), we need to have live bindings. Otherwisewill yield a pair of
undefined
paths.I think I know how to implement it (replace all references to named imported bindings like
foo
with__import1.foo
, replace allexports.foo = foo
withObject.defineProperty(exports, 'foo', { get: () => foo })
, it's just a bit of a nuisanceThe text was updated successfully, but these errors were encountered: