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

How did professors feelings about black well as a student change over time?
which number is 100 less than 38 tens
You sell pies at a farmers' market for $7.50 each. A group of 5 kids wants to pitch in equal1y to share one of your pies. How much will each of them need to pa
How do you do 720 divided by 10 with the exponet of 3
Why did the Chinese peasants rebel against the manchus from 1850 to 1864?
How long does water evaporation take? What factors influence it?
How many combinations of 3 students can a teacher choose from 32 students?   A. 96
Madison was driving at 40 mph and went 80 miles. How long did it take madison?
How many combinations of 3 students can a teacher choose from 32 students?   A. 96
which accurately describes a tangent