Jyoti Puri
Jyoti Puri

Reputation: 1346

Performance issue with React controlled components

I have been using react's controlled components in my application and .

But I am noticing that as I enter more and more inputs to these form components my page is slowing down badly or even hangs sometime.

Any clue ?

Upvotes: 3

Views: 1273

Answers (1)

Emil Ingerslev
Emil Ingerslev

Reputation: 4765

Sounds like you should look into the key="" attribute. Most often when react starts to slow down it is related to it doing more work than necessary. Another way to improve performance is implementing shouldComponentUpdate, but that should first be necessary later on.

Upvotes: 1

Related Questions