liltrell2568 liltrell2568
  • 02-12-2021
  • Computers and Technology
contestada

How to use a state value in stylesheet in react native.

Respuesta :

bushiaslam32008 bushiaslam32008
  • 05-12-2021

Answer:

Change this code:

return <View style={[styles.container, backgroundColor: this.state.bg]}/>

for this code:

return <View style={[styles.container, {backgroundColor: this.state.bg}]}/>

Answer Link

Otras preguntas

What is dancing on the hot black stove? A) a man with buttons B) small hard tears C) raindrops D) the clever almanac
Find x if they are similar
How many ways cancan 10 people be seated around the table can seat on any of the of the chairs? ​
Why did Nixon replace Vice President Spiro Agnew with Gerald Ford?
2c - 3b when C = 8 and b = 3.5
The diagram shows the locations of Gabe’s house, a library, and a gymnasium. Each unit on the grid represents 1 kilometer. Part C: Gabe’s friend Cindy lives hal
because a bacterium can only reach the cellular level
principal actividaf economica de puerto rico a inicios del sigloXVI​
Which statement best completes the Timeline the Thai kingdoms win their Independence. A Thailand establishes south east Asia first democracy B south east Asia i
How many sixteenth note are in one dotted-whole note?