| ▲ | dalmo3 3 days ago | |
> `child({ ...obj })` easily solves this, for example Spreading doesn't prevent you from mutating nested fields. The fact that you think this is an easy problem puts all your other choices under question. | ||
| ▲ | dashersw 3 days ago | parent [-] | |
Feel free to question anything you like and I'll help you find the answers. This is a well-trodden path. All aspects of object mutation and its effects are obvious and well-known. What is pass by ref and what is pass by val is also pretty obvious. One can easily pass in primitive values and not worry about two-way binding if they choose to. One can also easily not mutate any props they receive from their parents. This is already the best practice in eslint for like 10 years. This is not easy, this is trivial. I'd rather see some real concerns. | ||