Skip to content

Commit eef2fa9

Browse files
committed
text: return error on constructor
Blocked by #102
1 parent 49ee5e4 commit eef2fa9

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/dom/text.zig

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,16 @@ pub const Text = struct {
3838
pub const prototype = *CharacterData;
3939
pub const mem_guarantied = true;
4040

41+
// TODO add constructor, but I need to associate the new Text
42+
// with the current document global object...
43+
// > The new Text(data) constructor steps are to set this’s data to data
44+
// > and this’s node document to current global object’s associated
45+
// > Document.
46+
// https://dom.spec.whatwg.org/#dom-text-text
47+
pub fn constructor() !*parser.Comment {
48+
return error.NotImplemented;
49+
}
50+
4151
// JS funcs
4252
// --------
4353

0 commit comments

Comments
 (0)