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

During the process of sublimation, a. a solid turns directly into a gas. b. a solid turns into a liquid. c. a gas turns directly into a solid. d. a liquid t
True or false: you must always yield the right-of-way to persons who are blind.
Who led the mormons west along the mormon trail in 1846?
Which of these is not a genetic disorder? A .sickle-cell anemia B. Down syndrome C. cystic fibrosis D. chronic halitosis
If you wanted the item that cost the most at the top of the table, you would sort in descending order. true false
Use this image to answer the following question. When government sets a price for a good above equilibrium, there will be economic growth. economic loss. a shor
Clear cut inpassible boundaries separate the methods of paragraph development. True or False?
A white-blue star is hotter than a red star. T or F
What number could be replaced with p? 8/12 = P/3
The figure below shows two triangles EFG and KLM. Which step can be used to prove that triangle EFG is also a right triangle? Answer Prove that a + b is greater