react-modern-audio-player
react-modern-audio-player copied to clipboard
Next.js CSS Importing Rule
I am facing this error when I am trying to integrate this library into Next.js (Typescript)
./node_modules/react-modern-audio-player/dist/index.css Global CSS cannot be imported from within node_modules. Read more: https://nextjs.org/docs/messages/css-npm Location: node_modules/react-modern-audio-player/dist/index.es.js
Tried Solution: next.config.js
const withTM = require('next-transpile-modules')([
'react-modern-audio-player'
]);
module.exports = withTM({
reactStrictMode: true,
});
But no luck.
Could anyone help me with it? Thank you