aboutsummaryrefslogtreecommitdiff
path: root/src/z/html/Fragment.zig
diff options
context:
space:
mode:
authorNathan Reiner <nathan@nathanreiner.xyz>2026-10-08 17:44:46 +0200
committerNathan Reiner <nathan@nathanreiner.xyz>2026-10-08 17:44:46 +0200
commit0260f392c19db7911496172c7d43d1178c6215cb (patch)
treec5a1f8ff56d3ea727da1d8d29059fc046b102890 /src/z/html/Fragment.zig
parentec30b659dfd337f5edf512ea78032fe18251b704 (diff)
add html parser
Diffstat (limited to 'src/z/html/Fragment.zig')
-rw-r--r--src/z/html/Fragment.zig15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/z/html/Fragment.zig b/src/z/html/Fragment.zig
new file mode 100644
index 0000000..d05ad4a
--- /dev/null
+++ b/src/z/html/Fragment.zig
@@ -0,0 +1,15 @@
+const std = @import("std");
+const mod = @import("root.zig");
+const Element = mod.Element;
+
+const Self = @This();
+
+elements: []const Element,
+
+pub fn format(self: *const Self, writer: *std.Io.Writer) !void {
+ for (self.elements) |element| {
+ try element.format(writer);
+ }
+}
+
+pub const parse = mod.parser.fragment;