LuaLibraries: Add loc_noop
authorWuzzy
Thu, 24 Nov 2016 20:33:28 +0000
changeset 933 404dfa2f8a23
parent 932 86ddcaa6813a
child 934 dd382ad56f7e
LuaLibraries: Add loc_noop
LuaLibraries.wiki
--- a/LuaLibraries.wiki	Wed Nov 23 18:44:14 2016 +0000
+++ b/LuaLibraries.wiki	Thu Nov 24 20:33:28 2016 +0000
@@ -49,6 +49,11 @@
 
 Note these examples do _not_ violate Lua syntax, it is in your responsibility to follow the syntax rules listed above.
 
+==== `loc_noop(text)` (0.9.23) ====
+Just returns `text`. This function has the same syntax as `loc`. Like for `loc`, the text will be collected to be made available for translation.
+
+You can use this function if you want a make a string available for translation but don't want the string to be translated right now. This can come in handy if you need to store strings in variables and want do something like ´loc(variable_name)` later.
+
 == Utils ==
 
 This library includes miscellaneous functions to use, they are all independent of each other and can be used everywhere.