B
B
bpGusar2018-05-05 21:38:05
JavaScript
bpGusar, 2018-05-05 21:38:05

How to create a two-dimensional array in state and fill it?

How to create a 2D array in state and fill it with a loop?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
Maxim, 2018-05-05
@maxfarseer

Create: link (RU)
Then use setState to write... for example:

...
state = {
  myData: []
}
...

this.setState({ myData:  })

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question