Difference between revisions of "Module:ApplyPattern"
Jump to navigation
Jump to search
(Created page with "local p = {} function p.hello(frame) return 'Hello' end return p") |
m |
||
Line 1: | Line 1: | ||
local p = {} | local p = {} | ||
− | function p. | + | function p.apply(frame) |
− | return 'Hello' | + | return 'Hello, my ' .. frame.args[1] .. ' is ' .. frame.args[2] |
end | end | ||
return p | return p |
Revision as of 14:26, 17 August 2019
Custom module to apply either some wiki markup or a template to each item in a comma delimited list. Look at Template:Class for examples.
local p = {} function p.apply(frame) return 'Hello, my ' .. frame.args[1] .. ' is ' .. frame.args[2] end return p