As a quick fix, if you wrap the entire if/else in its own <div> (or any other tag) then it binds correctly.
I'm not sure if this is 100% correct, but for me it helps to think of each ejs block as a change callback function which gets bound to its parent element. If there's one immediate parent (like the <div>) then it all works out nicely, but if there are multiple siblings or multiple ejs tags within an element then it sometimes breaks.
I'm not sure if this is 100% correct, but for me it helps to think of each ejs block as a change callback function which gets bound to its parent element. If there's one immediate parent (like the <div>) then it all works out nicely, but if there are multiple siblings or multiple ejs tags within an element then it sometimes breaks.