feat: track dependencies when loading config with native#19374
feat: track dependencies when loading config with native#19374sapphi-red wants to merge 3 commits intovitejs:mainfrom
Conversation
@bluwy |
|
Writing a test for this is difficult. If I write a test in Vitest, the SSR transform replaces the dynamic import with the Vite's internal dynamic import function and the loader won't be called. To write a unit test that runs node command, I need to export the function but I don't want to export the function... |
|
I'm personally fine without a test for now if it's difficult. I wonder if it's also good to extract this code as its own package too. I imagine other packages in the ecosystem may also find this useful, and it'll indirectly simplify testing. But that's just my thought 😅 |
Description
reopen of #19350
Adds support for restarting the server when the dependency of the config file is edited.
I haven't wrote the tests yet.
refs #19178