`Component` doesn't updates on path change
Closed this issue · 2 comments
gbiryukov commented
Version
- tcomb-form v0.9.16
- react v0.15.4
Expected behaviour
Components gets re-rendered when its path changes.
Actual behaviour
tcomb Component
class has shouldComponentUpdate
defined that prevent component update on path
changes
Steps to reproduce
You will see that remaining element will have path 1.title
but it's actual path 0.title
.
If you will try to type something into this textbox it will pass incorrect path to form onChange
callback
It quite easy to fix in t.form.Component
shouldComponentUpdate
method
gcanti commented
@gbiryukov thanks for the detailed bug report, would you like to send a PR?
gbiryukov commented
sure, np