Hacker News new | past | comments | ask | show | jobs | submit login

I am quite a fan of HTMX and am using it for multiple projects now. I hope it continues to gain traction.



How do you handle things like menu pop-ups and toggling/hiding content? I keep wanting to use htmx and it's like, but there always seem to be very common tasks like having an expandable menu on mobile that don't have a great solution in these libraries and I have to write vanilla JS.

I've settled on Alpine instead for the time being because it has some data management built in. I'm thinking I'm going to have to switch to Vue on my current project because I feel so much less productive with Alpine.


htmx is focused on increasing the network-oriented expressiveness of HTML, rather than on pure front end enhancements.

For something like menu popups or toggling content on the front end, I would expect an application to use a front end framework like bootstrap, or perhaps WebComponents, or a scripting solution like Alpine, in conjunction with htmx.

Alpine and htmx complement one another nicely, particularly since htmx 0.2.0, when we started firing kebab-style event names.


Ah for whatever reason I always saw this as an either-or scenario, not in tandem.

That gives me hope as I’ve wanted to use htmx on a project. Gonna start playing around with it tonight. Thanks!


Basically, you can toggle visibility on your pop up menus or modals with standard CSS/HTML. The visibility class/attribute can be controlled declaratively or imperatively without much JS. You can even use CSS transitions to add nice smooth animation to your menu/overlay.

#UseThePlatform


Me too! As a developer mostly with desktop software development experiences, htmx is so much straightforward to understand and easy to code, it's a perfect chose for me to implement pages such as 'License Upgrade', 'License Renew', and so on: https://docxmanager.com/miscpages/upgrade-to-standard-from-b...


Do you have any examples or favorite articles about using it? I'm exploring the space, but have really limited time to sit down with all of the different options today. HTMX is one that is very intriguing.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: