--- layout: default nav: attributes > ic-trigger-on ---
ic-trigger-delay - The Trigger Delay AttributeThe ic-trigger-delay attribute tells Intercooler to delay the firing of a request in response
to a trigger until the specified time interval has passed. If the trigger occurs again before the interval
is complete, the earlier trigger will cancel and new trigger will begin waiting for the specified interval.
The value of the attribute should a valid integer, followed by the string "s" (for seconds) or "ms" (for milliseconds). (e.g. ic-poll="100ms" indicates that the server should be polled every 100 milliseconds.)
ic-trigger-delay has no dependency implications.
Here is a text box that updates a div with its content after a delay:
<input type="text" name="text"
ic-post-to="/text" ic-trigger-on="keypress" ic-trigger-delay="500ms"
ic-target="#text-div" ic-indicator="#indicator"/>
<i id="indicator" class="fa fa-spinner fa-spin" style="display:none"></i>
<br/>
Text: <div id="text-div"></div>
Note that the response to the button click is the content to swap in for the div, not the button.