Well with react-native we get the great benefits of flex container and additionally some transforms which we’re going to benefit from.
We’ll develop a credit. On touch press/grant we will find out the offset associated with the cards to touch and begin producing the transform to move/rotate the cards.
It is mostly hassle free after you jump in however.
Whatever you will not manage.
Physics. It is possible to put into action a bouncy spring system, but we are going to ensure that it it is easy with a drag principle.
Build an elementary cards
We are going to create a fundamental wrapper container then produce a cards View. We will focus everyting within our very own container utilizing alignItems and justifyContent both heart our very own cards will you need to be 300 by 300 , with a little cushioning, and border.
Given that we a general cards we are able to create seem a little nicer with an image, many book.
Put an Image/Text to card
We’re going to put a picture and set to a certain peak. There is certainly a current problem in react-native that does not keep facet ratio but that will be taken care of at some point.
We put our book details in View and rank each Text product about remaining and correct. You will find an approach to do this with flexbox but positioning along these lines are a little more specific.