Template:Xpds: Difference between revisions

    From Ianseo
    No edit summary
     
    m (1 revision imported)
     
    (No difference)

    Latest revision as of 10:08, 17 March 2025

    Template documentation

    This Template:xpds (expansion demo) shows the call of a variable, parser function or template and its result, for documentation. The call is the same as the template call to be demonstrated, except that "xpds|" is inserted after the opening braces.

    The template uses Module:Xpd; see also Module talk:Xpd.

    Examples:


    {{xpds|CURRENTTIME}} gives: {{CURRENTTIME}} → 21:01


    {{xpds|#expr:1/7}} gives: {{#expr:1/7}} → 0.14285714285714


    {{xpds|2x|abc}} gives: {{2x|[[abc]] }} → Template:2x


    {{xpds|2x|0.14285714285714}} gives: {{2x|0.14285714285714 }} → Template:2x


    {{xpds|t2demo|abc}} gives: {{t2demo||abc}} → Template:T2demo


    {{xpds|hook|ParserBeforePreprocess}} gives: {{hook|ParserBeforePreprocess}} → Template:Hook


    {{xpds|Foreach|hook|delim=,|ParserBeforePreprocess|ParserAfterTidy}} gives:

    {{Foreach|hook|ParserBeforePreprocess|ParserAfterTidy|delim=,}} → Template:Foreach

    See also