Force SVG imports to have "?raw" or "?url"
What does this MR do and why?
First half of #391589
Previously we always loaded all the svg files using the raw-loader but have since enabled our imports to load the URL as it's usually done with other images.
This forces our team to decide on a loader when fetching svgs, to they are more intentional about how they load SVG.
Why?
Most of the time, it makes more sense to import our SVG via url, as then we can add the url into <img src="svgPath" />
. We should eventually migrate most usages to use the src
method.
Screenshots or screen recordings
NA
How to set up and validate locally
I used the following to ensure I covered all the imports in the code:
rg --multiline "import.+(.+\.svg)"
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #390786 (closed)
Edited by Miguel Rincon