From 0af4f12223e4a3076aa3964d1cd41de1481eeb7d Mon Sep 17 00:00:00 2001 From: finanalyst Date: Thu, 9 Jul 2026 21:46:51 +0100 Subject: [PATCH] add example using plugin --- META6.json | 3 ++- bin/25-1-rakudoc-v2.raku | 39 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 41 insertions(+), 1 deletion(-) create mode 100644 bin/25-1-rakudoc-v2.raku diff --git a/META6.json b/META6.json index b0e6f56..3c932b9 100644 --- a/META6.json +++ b/META6.json @@ -12,7 +12,8 @@ "Air::Plugin::Wordcloud", "Air::Plugin::Rakudoc", "Air::Plugin::MailForm", - "Air::Plugin::Donate" + "Air::Plugin::Donate", + "Air::Plugin::RakuDoc" ], "description": "hArc stack website examples (HTMX, Air, Red, Cro)", "license": "Artistic-2.0", diff --git a/bin/25-1-rakudoc-v2.raku b/bin/25-1-rakudoc-v2.raku new file mode 100644 index 0000000..4866727 --- /dev/null +++ b/bin/25-1-rakudoc-v2.raku @@ -0,0 +1,39 @@ +#!/usr/bin/env raku + +use Air::Functional :BASE; +use Air::Base; +use Air::Plugin::RakuDoc; + +my &index = &page.assuming( + title => 'hÅrc', + description => 'HTMX, Air, Red, Cro', + footer => footer p ['Aloft on ', b 'Åir'], + ); + +my $base-examples = + site :register[Air::Plugin::RakuDoc.new], :!scss, + index + main + div [ + h3 'RakuDoc'; + rakudoc q:to/RAKUDOC/; + =document :!auto-toc + =begin rakudoc + =config item :bullet«\c[palm tree]» + =config item2 :bullet«\c[Earth Globe Europe-Africa]» + =head This is some RakuDoc source + + Lets include a snazzy list: + =item First item with a palm tree bullet + =item Second item with palm tree + =item2 Now a second layer with a world + =item Back to the palm tree + + And now some ordinary text. + =end rakudoc + RAKUDOC + hr; + + ]; + +$base-examples.serve; \ No newline at end of file