"Module build failed" with swc

default discord avatar
sejden
6 months ago
2

Hi, recently trying to update to v1.6, but I'm getting an error when trying to make a production build. I got to pinpoint the cause down to this commit: (introduced in

1.6.18

)

https://github.com/payloadcms/payload/commit/ef826c88ec40878bb36e960c2df2c68ec3c54ef6

If I comment that code out, compilation works again.



Any idea why it makes it fail to compile?


Here is the error I get:

  • discord user avatar
    jesschow
    Payload Team
    5 months ago

    Hey @sejden - I haven't seen this error before, are you still experiencing this on version 1.7.1?

  • default discord avatar
    sejden
    5 months ago

    Hi, thanks for the follow up. Unfortunately, yes, it's still happening with version 1.7.1. And still, when I remove the

    ignore

    from the swc options, build works again



    It seems to be related to Tailwindcss, as when I remove the @tailwind directives, build works again



    Seems to be working now with current version 🍪

Open the post
Continue the discussion in Discord
Like what we're doing?
Star us on GitHub!

Star

Connect with the Payload Community on Discord

Discord

online

Can't find what you're looking for?

Get help straight from the Payload team with an Enterprise License.