From cbbaee47d44bc61d594b11d677e36a73e20e1952 Mon Sep 17 00:00:00 2001 From: Elara6331 Date: Tue, 11 Feb 2025 16:43:43 -0800 Subject: [PATCH] Mention the ability to ignore missing includes/macros in README --- README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.md b/README.md index 41ff968..6ef17f7 100644 --- a/README.md +++ b/README.md @@ -129,6 +129,8 @@ The include tag allows you to import content from other templates in the namespa #include("header.html") ``` +If the file name starts with a question mark, nonexistent files will be ignored. + #### Using the `include` tag with extra arguments The `include` tag can accept extra local variables as arguments. Here's an example with a `title` variable: @@ -153,6 +155,8 @@ The macro tag is a powerful feature that allows you to define reusable template When a macro tag has a block, it sets the macro's content. When it doesn't, it inserts the contents of the macro. In the above example, a macro is defined and then inserted. +If the macro name starts with a question mark, nonexistent macros will be ignored. + #### Using the `macro` tag with extra arguments Similar to the `include` tag, the `macro` tag can accept extra local variables as arguments. You can define these variables when including the macro. Here's an example: