Skip to content

Is there a way to not trigger unless 3 characters have been typed? #1897

Answered by nastanford
nastanford asked this question in Q&A
Discussion options

You must be logged in to vote

I just found an answer not sure if it is the best answer but in case someone else needs this.

        <input class="col-4 form-control border-1 border-primary" type="search"
          name="search" placeholder="Enter the Student ID or Name"
          hx-get="/studentreporting/view/search/index.cfm?page=1"
          hx-trigger="keyup[target.value.length > 3] delay:1000ms, search[target.value.length > 3]"  
          hx-target="##searchResults"
          hx-indicator=".htmx-indicator"
          hx-boost="enter">

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@Telroshan
Comment options

@nastanford
Comment options

Answer selected by nastanford
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants