htmx is a JavaScript library which interprets a set of HTML attributes and JavaScript events. It doesn't have anything to do with static typing. However, it's fairly easy to add a statically-typed layer on top of it eg https://github.com/yawaramin/dream-html
Sure, but htmx doesn't have any opinion that those types should be statically checked. Anyone diligent enough can try to enforce it with enough work, but the juice may not be worth the squeeze.