Last active
April 23, 2024 08:58
-
-
Save ky-zo/a5fdd5988db86a83e8d95da402934d64 to your computer and use it in GitHub Desktop.
Modularize import of react-icons in next.config.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const nextConfig = { | |
//... | |
modularizeImports: { | |
'react-icons/?(((\\w*)?/?)*)': { | |
transform: '@react-icons/all-files/{{ matches.[1] }}/{{ member }}', | |
skipDefaultConversion: true, | |
}, | |
}, | |
//... | |
} | |
module.exports = nextConfig |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment