From e3740eb9075594d8a2e6e026c542b27f01fe8e9b Mon Sep 17 00:00:00 2001 From: Thomas Voss Date: Thu, 18 Apr 2024 10:46:14 +0200 Subject: Add support for comments --- gsp.5 | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) (limited to 'gsp.5') diff --git a/gsp.5 b/gsp.5 index 41b458c..b193657 100644 --- a/gsp.5 +++ b/gsp.5 @@ -1,4 +1,4 @@ -.Dd $Mdocdate: November 1 2023 $ +.Dd $Mdocdate: April 18 2024 $ .Dt GSP 5 .Os .Sh NAME @@ -34,6 +34,11 @@ html lang="en" { p #my-id {- This is a paragraph with the id ‘my-id’ } p .my-cls {- This is a paragraph with the class ‘my-cls’ } + / div { + p {- This entire div is commented out. } + p {- Isn’t that neat? } + } + p #some-id .class-1 @@ -99,6 +104,20 @@ Node names follow the exact same naming rules as names do in XML. See the XML reference in .Sx SEE ALSO for more details. +.Ss Comments +Comments can be created by using the special +.Sq / +node name. +During transpilation any nodes named +.Sq / +and their children are commented out: +.Pp +.Bd -literal -offset indent +div { + / p {-I am commented out} + p {-I am not commented out} +} +.Ed .Ss Attributes Attributes are optional components of a node. They take the form of an attribute name and an optional attribute value. -- cgit v1.2.3