Module:MultiTabs: Difference between revisions

From EarthMC
Jump to navigation Jump to search
(Created page with "local p = {} --p stands for package function p.create( frame ) local int = #frame.args return int end return p")
 
mNo edit summary
Line 1: Line 1:
local p = {} --p stands for package
local p = {} --p stands for package
function GetTableLng(tbl)
  local getN = 0
  for n in pairs(tbl) do
    getN = getN + 1
  end
  return getN
end


function p.create( frame )
function p.create( frame )
     local int = #frame.args
     local int = GetTableLng(frame.args)
     return int
     return int
end
end

Revision as of 21:38, 23 October 2023

local p = {} --p stands for package

function GetTableLng(tbl)
  local getN = 0
  for n in pairs(tbl) do 
    getN = getN + 1 
  end
  return getN
end

function p.create( frame )
    local int = GetTableLng(frame.args)
    return int
end


return p