▲ | athrowaway3z 2 days ago | |
The requirements are a bit too vague so i'm guessing here. The design were talking about is mutating local state to update the view. Unchanging variables (like a name from a db) are provided on construction and not relevant. Selecting a new contract to 'open' creates a new contract element. No need to update the existing element. ---- If you're talking about "if I edit <input> here it updates <input> there as well", than I believe those are gimmicks that reduce usability. If I understand your example correctly: a multi-contract view where the user updates a 'name' in both. IMO its a better UI to explicitly have the name:<input> _outside_ the contract elements. The contract element can do nameInput.onchange =(e) => {...} when constructed to update itself. |