Content deleted Content added
mNo edit summary |
Update the documentation |
||
Line 1,303:
| label2 = Repeatable | data2 = Yes
| header3 = See also
| data4 = <code>[[#imposing|imposing]]</code>, <code>[[#providing|providing]]</code>, <code>[[#sequential|sequential]]</code>, <code>[[#squeezing|squeezing]]</code>, <code>[[#filling_the_gaps|filling_the_gaps]]</code>, <code>[[#clearing|clearing]]</code>, <code>[[#cutting|cutting]]</code>, <code>[[#cropping|cropping]]</code>, <code>[[#purging|purging]]</code>, <code>[[#backpurging|backpurging]]</code>, <code>[[#rotating|rotating]]</code>, <code>[[#mirroring|mirroring]]</code>, <code>[[#pivoting|pivoting]]</code>, <code>[[#swapping|swapping]]</code>, <code>[[#discarding|discarding]]</code>, <code>[[#all_sorted|all_sorted]]</code>, <code>[[#reassorted|reassorted]]</code>, <code>[[#new|new]]</code>
}}
Line 1,328:
| label2 = Repeatable | data2 = Yes
| header3 = See also
| data4 = <code>[[#providing|providing]]</code>, <code>[[#discarding|discarding]]</code><!--, <code>[[#inserting|inserting]]</code>-->, <code>[[#filling_the_gaps|filling_the_gaps]]</code><!--, <code>[[#new|new]]</code>-->
}}
Line 1,342:
{{vpad|clear=none}}
{{A note}} The value
{{vpad|1.5em|clear=none}}
=== <code>providing</code> ===
{{Infobox|headerstyle=background:lavender
| titlestyle = font-weight:normal; font-size:100%;
| title = Modifier <code>providing</code> <span style="nowrap">({{module:params/doc/link to the code|providing|code}})</span>
| label1 = Num. of arguments | data1 = 2
| label2 = Repeatable | data2 = Yes
| header3 = See also
| data4 = <code>[[#imposing|imposing]]</code>, <code>[[#discarding|discarding]]</code><!--, <code>[[#inserting|inserting]]</code>-->, <code>[[#filling_the_gaps|filling_the_gaps]]</code><!--, <code>[[#new|new]]</code>-->
}}
; Brief
: ''Assign a new value to a parameter, but only when missing''
; Syntax
: <syntaxhighlight lang="wikitext" inline>{{#invoke:params|providing|name|value|pipe function name}}</syntaxhighlight>
Example:
<syntaxhighlight lang="wikitext">{{#invoke:params|providing|foo|bar|providing|hello|world|for_each|[$#: $@]}}</syntaxhighlight>
{{vpad|clear=none}}
{{A note}} The value assigned will not be trimmed of its leading and trailing spaces. The name of the parameter and the <code>providing</code> modifier name itself, however, will be trimmed of their surrounding spaces.
{{vpad|1.5em|clear=none}}
|