Comments (9)
I managed to get the icon to scale properly by applying scale={width/24}
to both of the path elements. Is there a better way to do this, though?
from react-native-svg.
Also, the viewbox dimensions should be the original dimensions of the shape.
from react-native-svg.
Just as an update, if you specify a viewbox
prop instead of viewBox
it works!
from react-native-svg.
I managed to get the icon to scale properly by applying
scale={width/24}
to both of the path elements. Is there a better way to do this, though?
Thanks ...I am using scale={0.5}
on Path
tag ...it's working fine
from react-native-svg.
viewBox should be all lowercase change it to viewbox
from react-native-svg.
viewbox
no more works.
Try viewBox
now.
from react-native-svg.
Fixed in 4.0.0-rc
Now you can use viewbox
or viewBox
both.
But using viewbox
will give a deprecated warning.
from react-native-svg.
I am using Tab Navigator(react-navigation) ,i placed the Icon over there,How to change the Active to inactive icon when i tap on other icons?
from react-native-svg.
How to scale differently same svg ?
from react-native-svg.
Related Issues (20)
- onPress in Path don't works on iOS, on android works
- The onPress method in the Path component works on android but not on ios.
- Svg Image pointerEvents="none" not working on Android
- Invalid `RNSVG.podspec` file: undefined method `visionos' for #<Pod::Specification name="RNSVG">. HOT 11
- Invariant Violation: requireNativeComponent: "RNSVGPath" was not found in the UIManager. HOT 2
- Fatal Exception: java.lang.Error Invalid number formating character 'N'
- SvgUri can not load some of the svgs in both android and ios
- Animating the strokeDashArray prop of an animated Path crashes running on the Android Simulator
- <Text /> with PanResponder only works if you click exactly on the letters
- Failed parsing SvgCssUri for first time, after reopening app it appears
- Xlinkhref only work on web does not work on ios and android (the color did not get inherited ) HOT 2
- React native web + vitest issue - Cannot use import statement outside a module HOT 4
- fetchText method error : TypeError: Cannot read property 'prototype' of undefined when trying to call svg from uri
- HTML entities contained in an XML string are not decoded by the SvgXml component
- Path not rendering correctly
- How to center Text along a path?
- React Native SVG stroke-width bug on expo web.
- SVG image not import in React native
- ForeignObject works with panResponder? HOT 1
- Why is `err` exported?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react-native-svg.