Skip to content
Saiko

require

Returns what a ModuleScript returns, sharing its state with the game. If the game has already run the module, you get the very table the game uses, with every change the game made to it.

Signature

luau
require(module: ModuleScript): any

Parameters

moduleModuleScript

The module to load.

Returns

any

Note

Example

luau
local module = game:GetService("ReplicatedStorage").Config
local config = require(module)

print(config == require(module)) --> true
print(config.Version)