- Sponsor
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
support this: extended css selector #2326
base: dev
Are you sure you want to change the base?
Conversation
What is the difference / added value compared to the already existing |
The form has two input fields, if i use In order to get the all input fields i use |
Oh ok indeed I see, I also complained back then about the inability to target multiple elements with the
Until then, as a workaround, note that you can put an ID or use any specific-enough selector to target elements within your form, such as <form id="whatever" method="GET" hx-trigger="input delay:500ms changed from:(#whatever input), submit">
<input type="email" name="email">
<input name="password">
</form> As said above, we aren't going to move forward with feature PRs until we get htmx 2.0 out so don't expect movement from our side on this before at least early April I'd say |
maybe should support a |
Alright, I've added a test for this feature. If this is going to be added i will update the docs accordingly.
I think that |
Hey, are you still interested in this change @gbourant ? |
hx-trigger now supports
this
as extended css selector, so we can do something like this:Also we might want to do(We can do this with :first-child/:last-child/:nth-child)thisFirst
(or something like that) which will use.querySelector
.If this is about to be added i will add the tests later.