Module:typing-aids/data/documentation

Hello, you have come here looking for the meaning of the word Module:typing-aids/data/documentation. In DICTIOUS you will not only get to know all the dictionary meanings for the word Module:typing-aids/data/documentation, but we will also tell you about its etymology, its characteristics and you will know how to say Module:typing-aids/data/documentation in singular and plural. Everything you need to know about the word Module:typing-aids/data/documentation you have here. The definition of the word Module:typing-aids/data/documentation will help you to be more precise and correct when speaking or writing your texts. Knowing the definition ofModule:typing-aids/data/documentation, as well as those of other words, enriches your vocabulary and provides you with more and better linguistic resources.

This module holds data indicating how to transform symbols/shortcuts into characters of the language in question. The data is used by Module:typing-aids and made available through {{chars}}. The return value of a module is a table holding replacements, in one of the following forms:

A list of replacements

This format is preferred, because it clearly specifies the order in which the replacements will happen. Each replacement is itself a two-element list { "FROM", "TO", before = "BEFORE_CONDITION", after = "AFTER_CONDITION" }:

  • "FROM" is a Lua pattern indicating what to replace;
  • "TO" is a Lua replacement expression, which can include references to parenthesized groups in the pattern, e.g. %1 to refer to the first parenthesized group;
  • before = "BEFORE_CONDITION" is a Lua pattern, and the replacement will only happen if the specified pattern occurs before the symbol being replaced;
  • after = "AFTER_CONDITION" is a Lua pattern, and the replacement will only happen if the specified pattern occurs after the symbol being replaced.

Both before and after are optional.

The order in which the replacements happen is top-to-bottom.

A table of key-value pairs

In this format, the key is a string (a Lua pattern indicating what to replace) and the value is either a string (a Lua replacement expression), or a table of the format { "REPLACEMENT", before = "BEFORE_CONDITION", after = "AFTER_CONDITION" }, where before and after are as above, and both are optional.

The order in which the replacements happen is undetermined; as a result, this format is dispreferred.

A list of tables of key-value pairs

In this format, the return value consists of multiple key-value tables as in the second format above. All replacements in the first table happen before those in the second table, but the order in which the replacements happen in a given table is still undetermined; as a result, this format is also dispreferred.

Replacements for some languages are found in subpages: