ATTENTION! The process of updating WiKi to version Eco 10.x has begun. Those wishing to participate can find out more Information on our ECO Contribution Wiki Discord.
From April 26 to May 12, errors may occur in the Wiki, as we will be carrying out a major update to the information processing modules.

Module:Utils/doc: Difference between revisions

From Eco - English Wiki
[checked revision][checked revision]
mNo edit summary
m (Add Usage section.)
 
Line 1: Line 1:
This module provides utility functions used from other modules.
This module provides utility functions used from other modules.


== Usage ==
Add the following line of code at the top of your file.
<syntaxhighlight lang="lua">local Utils = require("Module:Utils")
-- You may then call functions from this module in your script. For example:
local tableLength = Utils.tableLen(myTable)</syntaxhighlight>
[[Category: WikiModules]]
[[Category: WikiModules]]

Latest revision as of 16:42, 22 February 2022

This module provides utility functions used from other modules.

Usage[edit source]

Add the following line of code at the top of your file.

local Utils = require("Module:Utils")

-- You may then call functions from this module in your script. For example:
local tableLength = Utils.tableLen(myTable)