Skip to content

UMD and IIFE output formats are not supported for code-splitting builds. #1379

Answered by aklinker1
lishaduck asked this question in Q&A
Discussion options

You must be logged in to vote

Seems like it's trying to take more control of the build process, which WXT doesn't like.

You could configure it to build the sveltekit app in a separate build process, letting it build itself essentially, then grab the results and add whatever you need to the manifest.

Here's an example of doing an external build, in this case using vite to code-split a content script.

https://github.com/wxt-dev/examples/tree/main/examples/esm-content-script-ui

Specifically, here's where the external build step happens:
https://github.com/wxt-dev/examples/blob/f068a7c7b02048c91e6608804ad62091dfb2bbee/examples/esm-content-script-ui/modules/esm-builder.ts#L12

Replies: 1 comment 10 replies

Comment options

You must be logged in to vote
10 replies
@lishaduck
Comment options

@aklinker1
Comment options

@lishaduck
Comment options

@aklinker1
Comment options

Answer selected by lishaduck
@lishaduck
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants