all repos — hastyscribe @ 96f555e406559710dcfc11183f24507a4f74a1b1

A professional markdown compiler.

Clarified that => is preferred for defining macros.
h3rald h3rald@h3rald.com
Sun, 12 Mar 2017 13:24:28 +0100
commit

96f555e406559710dcfc11183f24507a4f74a1b1

parent

1b17825197cfd3344f648b4ff52de45e82b9e090

2 files changed, 9 insertions(+), 7 deletions(-)

jump to
M doc/-syntax.mddoc/-syntax.md

@@ -89,7 +89,7 @@ ## Macros

If snippets are not enough, and you want to reuse chunks of _similar_ content, you can define substitution macros using the following syntax: -<code>\{#greet -> Hello, $1! Are you $2?#\}</code> +<code>\{#greet => Hello, $1! Are you $2?#\}</code> This defines a macro called [greet](class:kwd) that takes two parameters which will be substituted instead of [$1](class:kwd) and [$2](class:kwd). To use the macro, use the following syntax:

@@ -101,6 +101,7 @@ >

> * Like snippets, macros can be multiline. > * Spaces and newline character are preseved ad the start and end of parameters. > * You can use snippets and fields within macros (but you cannot nest macros inside other macros). +> * You can define macros using either [->](class:kwd) or [=>](class:kwd), although [=>](class:kwd) is preferred. {@ -syntax-inline.md || 1 @}
M doc/HastyScribe_UserGuide.htmdoc/HastyScribe_UserGuide.htm

@@ -4706,7 +4706,7 @@ </thead>

<tbody> <tr> <td><code>{{$timestamp}}</code> </td> -<td> 1489321116</td> +<td> 1489321436</td> </tr> <tr> <td><code>{{$date}}</code> </td>

@@ -4730,19 +4730,19 @@ <td> 3/12/17</td>

</tr> <tr> <td><code>{{$short-time}}</code> </td> -<td> 13:18 PM</td> +<td> 13:23 PM</td> </tr> <tr> <td><code>{{$short-time-24}}</code> </td> -<td> 13:18</td> +<td> 13:23</td> </tr> <tr> <td><code>{{$time}}</code> </td> -<td> 13:18:36 PM</td> +<td> 13:23:56 PM</td> </tr> <tr> <td><code>{{$time-24}}</code> </td> -<td> 13:18:36</td> +<td> 13:23:56</td> </tr> <tr> <td><code>{{$day}}</code> </td>

@@ -4803,7 +4803,7 @@ <h3>Macros<a href="#document-top" title="Go to top"></a></h3>

<p>If snippets are not enough, and you want to reuse chunks of <em>similar</em> content, you can define substitution macros using the following syntax:</p> -<p><code>{#greet -> Hello, $1! Are you $2?#}</code></p> +<p><code>{#greet => Hello, $1! Are you $2?#}</code></p> <p>This defines a macro called <span class="kwd">greet</span> that takes two parameters which will be substituted instead of <span class="kwd">$1</span> and <span class="kwd">$2</span>. To use the macro, use the following syntax:</p>

@@ -4815,6 +4815,7 @@ <ul>

<li>Like snippets, macros can be multiline.</li> <li>Spaces and newline character are preseved ad the start and end of parameters.</li> <li>You can use snippets and fields within macros (but you cannot nest macros inside other macros).</li> +<li>You can define macros using either <span class="kwd">-></span> or <span class="kwd">=></span>, although <span class="kwd">=></span> is preferred.</li> </ul> </div>