Jump to content

Module:Listify

From Bronze and Iron: An Andal Invasions AGOT Roleplay Project
Revision as of 00:01, 19 April 2025 by Emmabirchtree (talk | contribs) (1 revision imported)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

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

return function (str)
  str = str or ""
  str = mw.ustring.gsub(str, "<br%s*/*>", "\n")
  str = mw.ustring.gsub(str, "<BR%s*/*>", "\n")
  str = mw.ustring.gsub(str, "^%*", "\n")
  str = mw.ustring.gsub(str, "\n%*", "\n")

  local t = {}
  for s in mw.ustring.gmatch(str, "([^\n]+)") do
    table.insert(t, s)
  end
  return t
end
Cookies help us deliver our services. By using our services, you agree to our use of cookies.