Anonymous
×
Create a new article
Write your page title here:
We currently have 97 articles on The Dream Shrine. Type your article name above or click on one of the titles below and start writing!



The Dream Shrine

Documentation for this module may be created at Module:String/doc

local p = {}

local utilsString = require("Module:UtilsString")

-- Escape , for the benefit of templates which split by ,
function p.Escape(frame)
	local str = frame.args[1]
	str = string.gsub(str, ",", ",")
	return str
end

-- Useful for converting template arguments to class names for which kebab-case is standard
function p.KebabCase(frame)
	local str = frame.args[1]
	return utilsString.kebabCase(str)
end

-- Applies <nowiki></nowiki> tags to the _output_ of a template, rather than applying it to the template transclusion itself
function p.Nowiki(frame)
	local str = frame.args[1]
	return frame:callParserFunction("#tag:nowiki", str)
end

-- Used by [[Template:Page Name]]
function p.StripTrailingParentheses(frame)
	local str = frame.args[1]
	return str and utilsString.stripTrailingParentheses(str)
end

return p