I'm new to HTMX and I have made this sample:
<!DOCTYPE html>
<html>
<head>
</head>
<body>
<script src="https://unpkg.com/htmx.org@1.8.4" integrity="sha384-wg5Y/JwF7VxGk4zLsJEcAojRtlVp1FKKdGy1qN+OMtdq72WRvX/EdRdqg/LOhYeV" crossorigin="anonymous"></script>
<form>
<button hx-get="https://google.com/">Click Me!</button>
</form>
</body>
</html>
So I tried loading the htmx script firstly and then used hx-get
to make a GET request for button.
But now the problem is, it does not work out at all!
It's like adding a button with no action and nothing also appears in the Console bar as js error!
So if you know how to call this htmx properly, please let me know..
Thanks.
UPDATE
I removed the <form>
tags and it looks like the htmx is now calling but retrieves these errors:
How to call htmx properly