react-google-calendar icon indicating copy to clipboard operation
react-google-calendar copied to clipboard

Support for Next.js

Open FunctionDJ opened this issue 3 years ago • 2 comments

It would be awesome if this component could support Next.js. It doesn't work right now because this module is importing CSS from node_modules, which Next.js "cannot support".

I've been looking for a Google Calendar component for Next.js for quite a while now, and this one looks really nice. Too bad i can't use it =(

FunctionDJ avatar May 28 '21 16:05 FunctionDJ

I just ran into this problem right now, I hope we can get a fix soon, nextjs is rejecting this library

as @FunctionDJ suggested From next js documentation https://nextjs.org/docs/messages/css-npm `Possible Ways to Fix It Reach out to the maintainer and ask for them to publish a compiled version of their dependency.

Compiled dependencies do not have references to CSS files, or any other files that require bundler-specific integrations.

The dependency should also provide instructions about what CSS needs to be imported by you, in your application.

Importing CSS files within node_modules cannot be supported because we cannot know the correct behavior:

Should the file be consumed as Global CSS or CSS Modules? If Global, in what order does the file need to be injected? If Modules, what are the emitted class names? As-is, camel-case, snake case?`

richardokonicha avatar Jun 09 '21 15:06 richardokonicha

Good news.

https://github.com/vercel/next.js/discussions/27953

italomarcos1 avatar Aug 16 '21 21:08 italomarcos1