Omit svg static imports if custom webpack config is defined (#26281)
This PR does a couple things: 1. Omit svg static imports if the user has defined custom webpack config with svg rule 2. Change TS type to `any` for svg imports to avoid conflicts with other plugins The idea is that some users want to use `next/image` with static imports for most image types but not for svg and instead inline those images with a plugin. - Fixes #25950 - Fixes #26130 - Fixes #26176 - Fixes #26196 - Fixes #26067 ## Bug - [x] Related issues linked using Fixes #26130 - [x] Integration tests added
Showing
| ... | @@ -43,6 +43,7 @@ | ... | @@ -43,6 +43,7 @@ |
| "@babel/preset-react": "7.12.10", | "@babel/preset-react": "7.12.10", | ||
| "@fullhuman/postcss-purgecss": "1.3.0", | "@fullhuman/postcss-purgecss": "1.3.0", | ||
| "@mdx-js/loader": "0.18.0", | "@mdx-js/loader": "0.18.0", | ||
| "@svgr/webpack": "5.5.0", | |||
| "@testing-library/react": "11.2.5", | "@testing-library/react": "11.2.5", | ||
| "@types/cheerio": "0.22.16", | "@types/cheerio": "0.22.16", | ||
| "@types/fs-extra": "8.1.0", | "@types/fs-extra": "8.1.0", | ||
| ... | ... |
This diff is collapsed.
This diff is collapsed.
Please
register
or
sign in
to comment