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

People flocked to California to fulfill the _________.
what were the cultural exchanges between the native American civilizations and the European settlers?
how many times is 5 bigger than 0.5?
what is the equivalent to 7.4 kilograms
Which pair of molecules both contain carbon atoms?
Another word for acadians
if you change the slope in the equation y= 5x + 7 to y = 2x + 7 how will its graph change? A. It will increase at a faster rate than before B. It will increase
round 44,769 to the nearest ten
The rise of China's naval power under Admiral Cheng-Ho occurred during the _______ dynasty
Which pair of molecules both contain carbon atoms?