Template:Lang/doc: Difference between revisions

Sur (talk | contribs)
m minor phrasing for label's description
Sur (talk | contribs)
m examples now dynamic
Line 6: Line 6:
=== Examples ===
=== Examples ===
==== Retrieve word by the attribute key ====
==== Retrieve word by the attribute key ====
<pre>English string: {{Lang|key=BonusClipSize_label}} -> "Ammo"</pre>
<pre style="width:fit-content;>English string: {{Lang|key=BonusClipSize_label}} -></pre> {{Lang|key=BonusClipSize_label}}<br><br>
<pre>French string:  {{Lang|key=BonusClipSize_label|lang_code=fr}} -> "Munitions"</pre>
<pre style="width:fit-content;>French string:  {{Lang|key=BonusClipSize_label|lang_code=fr}} -></pre> {{Lang|key=BonusClipSize_label|lang_code=fr}}<br><br>


==== Retrieve string by label ====
==== Retrieve string by label ====
<pre>English string: {{Lang|label=Ammo}} -> "Ammo"</pre>
<pre style="width:fit-content;>English string: {{Lang|label=Ammo}} -></pre> {{Lang|label=Ammo}}<br><br>
<pre>French string:  {{Lang|label=Ammo|lang_code=fr}} -> "Munitions"</pre>
<pre style="width:fit-content;>French string:  {{Lang|label=Ammo|lang_code=fr}} -></pre> {{Lang|label=Ammo|lang_code=fr}}<br><br>


<templatedata>
<templatedata>