From eaad5b6e648efed69dce6d326ffeafa718df234f Mon Sep 17 00:00:00 2001 From: The-Mighty-Cat <54977668+The-Mighty-Cat@users.noreply.github.com> Date: Wed, 12 Feb 2025 23:10:10 +0100 Subject: [PATCH] Created HtmlElement (markdown) --- HtmlElement.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 HtmlElement.md diff --git a/HtmlElement.md b/HtmlElement.md new file mode 100644 index 0000000..c0845dc --- /dev/null +++ b/HtmlElement.md @@ -0,0 +1,17 @@ +```cpp +namespace Crafter::CppDOM { + export class HtmlElement { + public: + void* const ptr; + inline HtmlElement(const char* id, std::size_t idLenght); + inline HtmlElement(const std::string& id); } + inline void SetInnerHTML(const char* html, std::size_t htmlLenght); } + inline void SetInnerHTML(const std::string& html); + inline ~HtmlElement(); + }; +} +``` + +The ``HtmlElement`` is an abstraction layer of HTML elements and bindings related to them. + +It is generally recommended to use this over raw bindings as this enforces memory safety with the destructor and is easier to use. \ No newline at end of file