Initial commit

This commit is contained in:
Jorijn van der Graaf 2025-01-02 02:48:44 +01:00
commit 2798e9567e
11 changed files with 363 additions and 0 deletions

17
sample/main.cpp Normal file
View file

@ -0,0 +1,17 @@
import Crafter.Web;
using namespace Crafter::Web;
int main() {
HtmlElement root("div", "", {}, {
HtmlElement("h1", "HELLO FROM C++"),
HtmlElement("h1", "blue text", {{"color","blue"}}),
HtmlElement("h1", "", {{"display","flex"}, {"justify-content","space-between"}}, {
HtmlElement("div", "c++"),
HtmlElement("div", "webdev"),
HtmlElement("div", "is"),
HtmlElement("div", "awesome")
}),
HtmlElement("img", "", {}, {}, {{"src","https://upload.wikimedia.org/wikipedia/commons/thumb/1/18/ISO_C%2B%2B_Logo.svg/1822px-ISO_C%2B%2B_Logo.svg.png"},{"width","200"}}),
});
root.RenderAsRoot();
}