diff website/src/manual.html.luan @ 1797:ba43135bb98d

backticks docs
author Franklin Schmidt <fschmidt@gmail.com>
date Sun, 11 Feb 2024 18:52:53 -0700
parents 7d2ab44f7a59
children f44dcb3fedf7
line wrap: on
line diff
--- a/website/src/manual.html.luan	Wed Jan 31 19:13:05 2024 -0700
+++ b/website/src/manual.html.luan	Sun Feb 11 18:52:53 2024 -0700
@@ -1788,6 +1788,28 @@
 <%
 						end
 					}
+					backticks = {
+						title = "Backticks"
+						content = function()
+%>
+<p>
+A block between backticks is run and then whatever was sent to standard output is returned as a string.  Examples:
+</p>
+<pre>
+	local s = `%&gt;1 + 1 = &lt;%=1+1%&gt;&lt;%`
+
+	local s = ` fn(whatever) `
+
+	local s = `%&gt;
+	...
+	&lt;%`
+</pre>
+<p>
+Backticks complement <a href="#template_stmt">template statements</a>.
+</p>
+<%
+						end
+					}
 				}
 			}
 			visibility = {