Module:Check DYK hook/doc

This module checks the format of Did you know hooks used in DYK talk and Article history.

Usage
This module can be used from templates or from other Lua modules.

From templates
From templates, call the  function, and use the hook parameter to specify the hook.

&#123;{#invoke:Check DYK hook&#124;isValidHook&#124;hook=hook}&#125;

Valid hooks will return a value of "yes"; invalid hooks will return the empty string.

You can also use the first positional parameter to specify the hook. If you do this, it is recommended to use 1 explicitly; if not, and the hook contains an equals sign, the text before the equals sign will be treated as a parameter name and the hook will not be recognised.

From modules
From modules, call the  function with the hook as the first positional parameter.

Valid hooks will return ; invalid hooks will return.