Fork me on GitHub
#hoplon
<
2021-06-09
>
denis_krivosheev07:06:28

Hello everyone. I decided to try hoplon once again, this time with shadow-cljs. I've taken the re-frame template and adapted it to work with hoplon. Actually it works quite nice, except one think that I'm not able to mitigate. Here is the code: https://github.com/denistakeda/umin/blob/master/src/umin/core.cljs#L25 The main problem is this input element, it behaves quite weird. First of all its value attribute is set not on change, but actually only on blur. Other think is when I set the new-item to "" in the on-click handler of a button, it's just ignored (the cell itself is resat, but input still includes the old string). At a first glance it looks like a bug with value attribute, but I'm not sure. I use hoplon 7.2.0

flyboarder16:06:02

you should be using the :change attribute on input fields to get the value as the user types

flyboarder16:06:21

you should be able to resolve this by wrapping new-value in a formula cell

alandipert18:06:34

hm i've used keydown to get the value instantly, i think change might require blur