react-native-shadow-2 icon indicating copy to clipboard operation
react-native-shadow-2 copied to clipboard

Draw a shadow around an svg

Open RobinBobin opened this issue 1 year ago • 1 comments

Hi, Is it possible to use your package to draw a shadow around an SvgXml from react-native-svg?

<Shadow>
  <SvgXml
    xml={`
    <svg height='100%' width='100%'>
      <rect fill='yellow' height='50%' width='50%' x='25%' y='25%' />
    </svg>
  `}
  />
</Shadow>

results in the svg not displayed. <Shadow><Text ... /></Shadow> from the readme renders fine.

Thanks.

RobinBobin avatar Aug 29 '24 10:08 RobinBobin

Hi, I can not tell why this doesn't work. Maybe nested svgs in this way don't work. Maybe try to wrap the SVG with a view?

ftzi avatar Aug 29 '24 10:08 ftzi

Closing due to inactivity

ftzi avatar Oct 26 '24 11:10 ftzi