diff options
| author | Stanisław Zagórowski <hasohasacz@gmail.com> | 2024-01-11 02:20:44 +0100 |
|---|---|---|
| committer | Stanisław Zagórowski <hasohasacz@gmail.com> | 2024-01-11 02:20:44 +0100 |
| commit | 343bcfdfaaba32b7a46e1a945a4538e72d166ea8 (patch) | |
| tree | ed27311160054515b6375a9f92e092772300ee65 /example/reluax.lua | |
huh whuh
Diffstat (limited to 'example/reluax.lua')
| -rw-r--r-- | example/reluax.lua | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/example/reluax.lua b/example/reluax.lua new file mode 100644 index 0000000..0a5f2c7 --- /dev/null +++ b/example/reluax.lua @@ -0,0 +1,20 @@ +local index = require("index") + +math.randomseed(os.time()) + +local function route(path) + if path == '/' then + return index() + elseif path == '/goodbye' then + return "goodbye" + elseif path == '/random' then + return 'no more random' + end + + return nil +end + +return { + name = "hello-world", + route = route +} |
