Rendering template
This commit is contained in:
parent
abe676f512
commit
815ff4bf4e
3 changed files with 71 additions and 0 deletions
27
lib/Config.rakumod
Normal file
27
lib/Config.rakumod
Normal file
|
@ -0,0 +1,27 @@
|
|||
use v6.e.PREVIEW;
|
||||
|
||||
use HTML::Functional;
|
||||
use DB::BlogMeta;
|
||||
|
||||
unit class Config;
|
||||
|
||||
method generate-post(Str:D $title, Str:D $content, BlogMeta:D $meta) {
|
||||
my $head =
|
||||
head [
|
||||
meta :charset<utf-8>;
|
||||
meta :name<viewport>, :content<width=device-width, initial-scale=1>;
|
||||
# meta :name<description>, :content<raku does htmx>;
|
||||
title "";
|
||||
];
|
||||
my $body;
|
||||
# my $footer;
|
||||
|
||||
die "Not done yet";
|
||||
|
||||
my $html = html :lang<en>, [
|
||||
$head,
|
||||
$body
|
||||
];
|
||||
|
||||
"<!doctype html>$html"
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue