feat: Reimplement support for true ESM mode #48
Labels
dev server
Issues concerning the Development Server
enhancement
New feature or request
help wanted
Extra attention is needed
Milestone
For the sake of the project's simplicity during the v2 rewrite, support for ES Modules have been temporarily dropped.
Major issues in supporting ESM is the lack of access to module cache (as opposed to CJS
require.cache
), so custom URL hashing, dependency chain tracking, and cache invalidation will all have to be developed (which is possible as seen in v1, but is extremely messy and still have disparities between the two modes).In future versions, module loading could possibly be handled via messages in a client-server architecture, possibly unifying the handling for both CJS and ES modules and resulting in a clearer API.
Relevant links:
The text was updated successfully, but these errors were encountered: