bigskysoftware / idiomorph

A DOM-merging algorithm
BSD 2-Clause "Simplified" License
693 stars 33 forks source link

htmx - possible to preserve input value? #29

Closed bartoszkrawczyk2 closed 9 months ago

bartoszkrawczyk2 commented 9 months ago

Hi, is there any way to preserve input value after swap?

bartoszkrawczyk2 commented 9 months ago

It can be achieved with: hx-swap="morph:{ignoreActiveValue:true}".

Can be closed now.

cj commented 4 months ago

@bartoszkrawczyk2 I tried this with hx-swap-oob but it tries to use {ignoreActiveValue:true} as part of the selector.

htmx__org.js?v=9dcca19b:533 Uncaught DOMException: Failed to execute 'querySelectorAll' on 'Document': '{ignoreActiveValue:true}' is not a valid selector.