Home > OS >  Draw the outline of a shape in react native
Draw the outline of a shape in react native

Time:01-17

I want to draw a rectangle in react native with a black outline and transparent center. I am able to draw a rectangle but I am not able to make its center transparent. Here is an expo example of how I'm drawing a rectangle: enter image description here

CodePudding user response:

Just use ViewStyleProps in react-native.

I modified your example and commented here: https://snack.expo.dev/@pqv2210/rectangle-drawing

  • Related