local page_wrapper = function(content) return reluax.html_page( reluax {$ content $} ) end local route = function(path, method, body) if path == "/" and method == "GET" then return 200, page_wrapper(

reluax

Click the button to get a random number.

) elseif path == "/random" and method == "POST" then return 200, reluax.html(

{$ math.random(1, 100) $}

) end return 404, page_wrapper(

reluax

404 Not Found

) end return { name = "htmx-example", route = route }