22 lines
533 B
C++
22 lines
533 B
C++
|
|
/*
|
||
|
|
catcrafts.net
|
||
|
|
Copyright (C) 2025 Catcrafts
|
||
|
|
|
||
|
|
The source code of this website is made available for viewing purposes only.
|
||
|
|
No permission is granted to copy, modify, distribute, or create derivative works.
|
||
|
|
*/
|
||
|
|
|
||
|
|
export module Catcrafts:Blog_impl;
|
||
|
|
import :Blog;
|
||
|
|
import std;
|
||
|
|
|
||
|
|
namespace Catcrafts {
|
||
|
|
std::string RenderBlog() {
|
||
|
|
std::string html = "";
|
||
|
|
for(const BlogPost& post : *posts) {
|
||
|
|
html += std::format("{}<br>{}<br><br>{}", post.name, post.date, post.content);
|
||
|
|
}
|
||
|
|
return html;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|