kristerkari / react-native-svg-transformer

Import SVG files in your React Native project the same way that you would in a Web application.
MIT License
1.58k stars 115 forks source link

Could we add support for optional import svg as a string not a `SvgComponent`? #311

Open FrozenPyrozen opened 11 months ago

FrozenPyrozen commented 11 months ago

I wanted to have the ability to import not only SvgComponent as react native component, but allow import svg icon as text. Smth similar we got in svgr, which allows us to import url like `import svg from './assets/file.svg?url'. For now I'm not sure how to do this https://react-svgr.com/docs/webpack/#use-svgr-and-asset-svg-in-the-same-project

image
apetta commented 5 months ago

This would be nice to have! I've been unable to get metro's resolver.resolveRequest to strip the query string