Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Can't import any Igloo component in NextJS project #413

Open
williamgraver opened this issue May 31, 2023 · 1 comment
Open

[Bug]: Can't import any Igloo component in NextJS project #413

williamgraver opened this issue May 31, 2023 · 1 comment
Labels
bug Something isn't working in backlog Pull requests for chore team

Comments

@williamgraver
Copy link

Contact Details

william.graver@gsoft.com

What happened?

Hello,

I'm trying to learn NextJS and I wanted to use one of the Igloo components in my project. It looks like there is a compilation issue due to the way CSS are exported in the different packages in the library.
image
See thread in the next.js project : vercel/next.js#19936

Here's my repo if you want to reproduce : https://github.com/williamgraver/randomlistpicker-api/blob/master/components/picker.jsx

Component

All

Component Version

latest

Which browsers are you seeing the problem on?

No response

Mobile Device

No response

Relevant log output

No response

@williamgraver williamgraver added the bug Something isn't working label May 31, 2023
@franckgaudin
Copy link
Member

To solve this problem, add thisTranspilePackages to next next.config.js config

const nextConfig = {
  transpilePackages: ['@igloo-ui'],
};
 
module.exports = nextConfig;

@franckgaudin franckgaudin added the in backlog Pull requests for chore team label Jul 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working in backlog Pull requests for chore team
Projects
None yet
Development

No branches or pull requests

2 participants