URL bundled assets and Single File Executable (SFE) #1204
thescientist13
started this conversation in
Ideas
Replies: 1 comment
-
Just a heads up on this bug that came up during alpha testing the original feature - #1210 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Overview
Coming out of the PR for #1186 , a couples techniques / refactorings were applied around the usage of
URL
for consuming assets with project files and for combining user page routes and the underlyingexecuteRouteModule
implementation.For example, a user could write this in an API route
And when bundling SSR pages for production, Greenwood do something like this
Problem Statement
Not so much a "problem" per se, since this technique works really and is standards compliant, but will never allow us to totally self contain a bunch of files down to one. For example, when bundling an SSR page, you will always have a single output file (good) but also need a "chunk" file that is the by product of the above mentioned bundling approach.
Or for an API route, an adjacent chunk
It does mean for adapters they do need to do something like, and manually copy over any assets of say an API route
h3. Thoughts
So not so much a good or bad thing, or if anyone would really notice and or want it improved from a user perspective, but there is something really nice a about a final single file artifact that can be deployed all one. Maybe there is a way to convert a URL into something more like an
import
statement that could then be inlined?Anyway, more thinking out loud, hence the discussion.
Beta Was this translation helpful? Give feedback.
All reactions