Bug: build failure with error "Default condition should be last one" #1011
Labels
bug
Something isn't working
Status: Unconfirmed
A potential issue that we haven't yet confirmed as a bug
Is there an existing issue for this?
Which Mux Elements/Packages does this apply to? Select all that apply
mux-player-react
Which browsers are you using?
Chrome
Which operating systems are you using?
macOS
Description
Currently not directly consuming the mux library but via a nested dependency in my next app like so:
app -> dependency A -> dependency B -> @mux/mux-player-react
when trying to run
next build
, I get the following error:When I rearrange the exports from this:
to this:
the build is fixed.
Using node v18.14.2, next v14.2.18.
node docs seem to specify that default should always come last
Webpack docs also seem to infer that default should be the last condition but also to avoid it as it can be "handled differently between tooling"
Current Behavior
next build fails with
Module not found: Default condition should be last one
Expected Behavior
next build should be successful
Errors
No response
What version of the package are you using?
No response
The text was updated successfully, but these errors were encountered: