-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Custom bundle loaders + WASM support -> master (#565)
* add support to rust/wasm * use child-process-promise instead of async-child-process * use parent extension instead of fromHtml flag * create WasmAsset * RustAsset refactor get rid of wargo use wasm32-unknown-unknown * fix lint errors, remove toml package and delete jsconfig.json * Inline wasm into JS, instantiate, and return exports * Split bundle loaders into separate modules Register custom loaders with `bundler.addBundleLoader` * Split out build queue logic into its own class Enables `bundler.getAsset` method to resolve and process an asset at any time, outside of the normal asset tree construction. * Only add a single asset to bundle if raw packager is used This gives us a separate bundle for each output file. * Include used bundle loaders, and preload external modules Allows synchronous import to preload modules in external files, e.g. .wasm file, prior to execution of the JS bundle. Also processes the HMR runtime like other assets. * Register wasm loader * Replace dedicated WASMAsset with RawAsset No longer returns a URL to the JS bundle if there is a bundle loader defined. This will cause the asset to be preloaded prior to JS bundle execution. * Update tests * Clean up bundling code * Hopefully fix test in travis * wasm tests * Define correct wasm mime type Until pillarjs/send#154 is merged. * Use WebAssembly.instantiate instead of constructor Should fix error “WebAssembly.Instance is disallowed on the main thread, if the buffer size is larger than 4KB” * Fix test * Fix PromiseQueue bug * Remove rust for now. Will be added in a separate PR.
- Loading branch information
1 parent
b80e523
commit 1a8ceb7
Showing
33 changed files
with
577 additions
and
160 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
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
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.