Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Merge compact and non-compact import.meta.url mechanisms * Extract more common code * Add option to configure import.meta.url resolution * Switch to using a plugin hook * Extract more common code * Move functionality into default plugin * Improve SystemJS handling * Refactor import.meta.url handling * Fix, refactor and test asset emission * Extract ModuleLoader * Use sets for colouring hashes * Simplify alias generation * Attach aliases to modules * Transform loading into a process that dynamically accepts new entry points and manual chunks * Pass alias objects through the module loader * Implement basic chunk emission * Allow duplicate entry points again * Rename addEntry -> emitEntryChunk * Simplify alias handling by immediately assigning a chunkAlias to entry points and introducing a manualChunkAlias for colouring to resolve this confusing double use of chunkAlias * * Allow manual chunks to contain nested entry points * Allow manual chunks to contain entry points without name or with the same name * Throw if an emitted chunk is not found * Throw if there is a conflict between manual chunk entries * Allow nesting of manual chunks without requiring a specific order * Manual chunks never conflict with entry points: - if the alias matches, the manual chunk becomes the entry chunk - otherwise a facade is created * Return correct file name if a facade is created for an emitted chunk * Start using central error handlers * Improve plugin driver type, add generic resolveFileUrl hook * Test new resolveFileUrl hook, make meta properties tree-shakeable * Move setAssetSource failure tests to function * Test and extract all errors thrown when emitting assets * Extract and refine error when chunk id cannot be found * Fail if filename is not yet available * Fail when adding a chunk after loading has finished * Do not access process.cwd() unchecked * Move isExternal to module loader * Fix typing of resolveId context hook * Refine worker test * Revert to "wrong" resolveId type as this will probably be fixed in a separate PR * Suppress .js extensions for AMD, fix issue with empty dynamically imported chunks * Use generated chunk naming scheme for emitted chunks and rename context function to `emitChunk` * Allow emitted chunks to be named * Add paint worklet example * Update documentation * Add reference ids to resolveFileUrl and replace type * Do not require `input` to be set if a dynamic entry is emitted * Use facade module id as [name] for dynamic imports * Update documentation * Refine pluginDriver types (ported from add-entry branch) * Make sure resolveId is always passed either string or null * Unify parameter names * Add new this.resolve context function * Get rid of dynamic import alias * Make sure resolveDynamicImport behaves the same as resolveId if an object is returned * Test new warnings and errors * Mark this.resolveId and this.isExternal as deprecated * Extract more errors * Use error message generators instead of error generators * Fix documentation ordering * Mark utility functions deprecated in types * Use relative ids in error messages
- Loading branch information
1 parent
18829da
commit 856707c
Showing
68 changed files
with
927 additions
and
300 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.