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

HELPP Rain forests are often cleared to provide land for farming. Which of these outcomes is the most immediate effect of this practice on the global environmen
What effect could an excess of thyroid-stimulating hormones have on your body?
Help me pleaseeee I’ll make u brianlist
Suppose that five graduating seniors on a college basketball team receive the following first- year contract offers to play in the National Basketball Associati
Which of the following is not a polynomial?
It's a silly concept, isn't it? Loving someone before you have even met them. This should lead you to wonder if Romeo's love is genuine and an act of fate, or i
Find the value of x. (3x + 10) 98°
what changes resulted from industrialization in the united states in the late 19th and early 20th centuries
families as a wholesale tend to resist change and strive to preserve what is normal. ​
As an estimation we are told £3 is €4. Convert £6 to euros.