The next generation Luau runtime.
Write Luau, run it right away, and ship a single small executable. Lehua gives you native multithreading, a batteries included standard library, and native DLL support. It is built in Rust for speed and safety.
--#include[fs]
print("hello from " .. __dirname)
-- run a second file on its own thread
local worker = parallel("./worker.luau")
worker:Push(21)
print(worker:Pop()) -- 42
fs.write("./out.txt", "done")
Lehua runs Luau like a compiled language. When you are ready, it packs your whole program into one small executable that needs nothing else to run.
Tree shakes your modules and writes a single executable. No runtime to install on the target machine.
The parallel keyword runs a file on its own thread and its own VM, with a channel to talk to it.
Call native code with an inject header. Referenced libraries get packed into the final build.
Fast and safe, on top of mlua and tokio, with the Luau native code generator turned on.