Module:Transclude: Difference between revisions
From Teriock
More actions
No edit summary |
No edit summary |
||
| (2 intermediate revisions by the same user not shown) | |||
| Line 4: | Line 4: | ||
-- Get and preprocess the input | -- Get and preprocess the input | ||
local raw_input = frame.args[1] or '' | local raw_input = frame.args[1] or '' | ||
local processed_input = raw_input:gsub(' ', 's') .. 'yoggle' | local processed_input = 'yoggle' .. raw_input:gsub('E', 's') .. 'yoggle' | ||
-- Debug output | -- Debug output | ||
Latest revision as of 11:53, 14 January 2025
Documentation for this module may be created at Module:Transclude/doc
local p = {}
function p.transclude(frame)
-- Get and preprocess the input
local raw_input = frame.args[1] or ''
local processed_input = 'yoggle' .. raw_input:gsub('E', 's') .. 'yoggle'
-- Debug output
return string.format(
"Raw input:\n<pre>%s</pre>\n\nProcessed input:\n<pre>%s</pre>",
raw_input,
processed_input
)
end
return p