Closed moxplod closed 2 months ago
Hi! Thank you for checking out Hydro and for kind words :)
Ad 1. You can use GitHub discussions for now. No discord yet.
Ad 2.
You have access to your Principal through regular HttpContext.User
in any place in the component. You can also inject any service to your component, including your authentication services.
Ad 3. There are no issues, but only if the HTMX manipulations are not changing the Hydro views. In other way, the views might get inconsistent. I believe that the features of Htmx you mentioned can be potentially replaced with Hydro navigation and events. If you are in doubt, let me know about your use-case.
Thanks for 1 and 2 - I will try it out.
For 3 - I totally see the use of Hydro and the DX improvement for me when I have a fully self-contained component. And I plan to use it for that purpose with HTMX. The way I have the application structured is that the view components (VC) are not always self-contained, and I use a lot of partial views as well. Would be curious to hear your thoughts on how to implement these use cases with Hydro.
Examples -
<body hx-boost="true" hx-target="#main" hx-swap="innerHTML show:window:top">
<div id="layout-wrapper">
<partial name="_Topbar"/>
<partial name="_Sidebar"/>
<div class="main-content">
<div class="page-content">
<div class="container-fluid">
<div id="main" hx-history-elt>
@RenderBody()
</div>
</div>
</div>
<partial name="_footer"/>
</div>
</div>
</body>
Ad 3. There are no issues, but only if the HTMX manipulations are not changing the Hydro views. In other way, the views might get inconsistent. I believe that the features of Htmx you mentioned can be potentially replaced with Hydro navigation and events. If you are in doubt, let me know about your use-case.
Hydro navigation and events If want to replace htmx, I hope Hydro's API or its usage can be simple enough. The simpler the better.
The selling point of htmx is returning to html and returning to simplicity.Hydro seems a bit cumbersome to use.
@moxplod for all your use cases you could use features that Hydro provides.
IsEditMode
. If it's true you return edition form, if it's false then you show the read-only data.hydro-link
which is similar to hx-boost
. It will morph the document into the new version, which should do the work. I could see something like hydro-link-target
in Hydro as an improvement, which would do similar thing as hx-target. What's the reason of updating only #main
element in your case? You do it to send less content from the server? Or server sends the whole page with layout anyway, but then htmx is exchanging only #main
?@sgf could you say something more about Hydro being cumbersome to use?
I'm closing since I didn't get any response from you. Will reopen if needed.
Hi, I just came across Hydro. Looks awesome. I have been using HTMX + .net MVC for all my front end for over a year now.
A few questions -
Thanks in advance.