Couldn't load preferences. Check your connection and try again.
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.
Module:Sort
From Teriock
More actions
Revision as of 23:39, 18 January 2025 by Gpe(talk | contribs)(Created page with "local p = {} function p.parse(frame) local input = frame.args[1] or "" local items = {} for item in string.gmatch(input, "([^,]+)") do table.insert(items, item:match("^%s*(.-)%s*$")) -- Trim whitespace end table.sort(items) return frame:preprocess(table.concat(items, ", ")) end")
Documentation for this module may be created at Module:Sort/doc
localp={}functionp.parse(frame)localinput=frame.args[1]or""localitems={}foriteminstring.gmatch(input,"([^,]+)")dotable.insert(items,item:match("^%s*(.-)%s*$"))-- Trim whitespaceendtable.sort(items)returnframe:preprocess(table.concat(items,", "))end