-
-
Notifications
You must be signed in to change notification settings - Fork 390
Description
Debouncing does not work when it is used on a child component that is linked to the parent through data-model.
Let's say we have a child component called searchField with an input.
<input type="search" data-model="value" />and a parent that uses this component linking data-model to a prop named query
<twig:searchField data-model="query:value" />If one wishes to delay the re-render by debouncing the input field the only place where this would be accepted is the child component
<input type="search" data-model="debounce(500)|value" />But this has no effect. The parent data-model gets updated immediately triggering the re-render.
I have notice that many other modifiers work as expected. For instance, min_length would prevent to update the parent if the length requirement is not met.
Trying to do the same thing on the the parent
<twig:searchField data-model="debounce(500)|query:value" />triggers an error Can't get a way to read the property "debounce(500)|query.