megh
megh

Reputation: 301

How to add box-shadow in React Native

I'm trying to recreate the shadow in the image below and need some help.

What CSS property should I use for this? I know I need border-radius, but I’m not sure what other property will help me achieve the desired results.

The red area in the image highlights the section I'm trying to replicate:

enter image description here

Upvotes: 1

Views: 715

Answers (2)

Firas
Firas

Reputation: 13

Can you put your code so we can see where's the problem? But you can use these properties to change it:

borderBottomRightRadius:value,
borderBottomLeftRadius:value

Example:

borderBottomRightRadius:10

Upvotes: 0

Charles Lavalard
Charles Lavalard

Reputation: 2321

Take a look at the box-shadow property (Docs here)

.card {
  border-radius: 10px;
  height: 100px;
  width: 200px;
  box-shadow: 0px 5px 6px -1px #58585838;
}
<div class="card">
</div>

Upvotes: 1

Related Questions