Trying to add SVGR into the next.js project.
The issue with a building project, getting error:
Module not found: Can't resolve '@svgr/webpack'
Setps:
Installed svgr as devDependecies
Add svgr into next.config.js
webpack: (config) => {
config.module.rules.push({
test: /\.svg$/i,
issuer: /\.[jt]sx?$/,
use: ['@svgr/webpack'],
});
Import svg file as Component
Build the project and error happens
Has anyone had a similar problem?