luau
luau
local luau = require("@std/luau")luau.compile
Compiles Luau source code into bytecode.
luau
(source: string) -> Bytecodeluau.load
Loads bytecode into a callable function. chunkname names the chunk for error messages.
An optional env table can be provided to override the global environment for the loaded chunk.
luau
(bytecode: Bytecode, chunkname: string?, env: { [any]: any }?) -> (...any) -> ...anyluau.loadModule
Loads and executes the Luau file at requirePath, returning its result.
An optional env table can be provided to override the global environment.
luau
(requirePath: path.Pathlike, env: { [any]: any }?) -> anyluau.resolveModule
Resolves the require path modulepath relative to frompath, returning the absolute path.
luau
(modulepath: string, frompath: path.Pathlike) -> path.Pathlikeluau.typeofModule
Returns the type pack representing the return types of the module at modulepath, or nil if unavailable.
luau
(modulepath: path.Pathlike) -> TypePack?