Closed tosaken1116 closed 8 months ago
Hi @tosaken1116
Thanks for your comment.
Therefore, if root is set in the config, how about we automatically insert root into these parts unless there's specific config for
ROUTES
,RENDERER
,NOT_FOUND
, andERROR
?
Yeah, I also would like to make that! But, it can't by limitation of Vite:
You should also be aware that all the arguments in the
import.meta.glob
must be passed as literals. You can NOT use variables or expressions in them. https://vitejs.dev/guide/features#glob-import-caveats
So, unfortunately, we can't use variables in the path for import.meta.glob
as you wrote π’
Thank you for your reply! I apologize for making a suggestion without knowing the specifications of Vite.π
I'm looking forward to the future development of the framework!!
I apologize for making a suggestion without knowing the specifications of Vite.π
No problem!
I'm looking forward to the future development of the framework!!
Thanks!
I'll close this issue!
What is the feature you are proposing?
Thank you for developing a great framework! Currently, I am developing using Honox. I've set the routes directory to
src/app/routes
, and to accommodate this, I made the following changes in src/app/server.ts:Even though root is set, I found it inconvenient that changes to
RENDERER
andROUTES
are required for pages to reflect. Upon inspecting the source code, I noticed that all four stringsROUTES
,RENDERER
,NOT_FOUND
, andERROR
contain/app/routes
. Therefore, if root is set in the config, how about we automatically insert root into these parts unless there's specific config forROUTES
,RENDERER
,NOT_FOUND
, andERROR
?For example, for
NOT_FOUND_FILE
: