Skip to content

Fails with has and direct child selector #43

@ViRb3

Description

@ViRb3

Problem

Cascadia seems to fail with the has psudo-class and a direct child selector

From MDN

The following selector matches only elements that directly contain an child:
a:has(> img)

Cascadia test

var selectorTests = []selectorTest{
	{
		`<html><a><img></img></a></html>`,
		"a:has(> img)",
		[]string{
			"<a><img></img></a>",
		},
	},
        ...
}

Result

selector_test.go:651: error compiling "a:has(> img)": expected identifier, found > instead

Is there any chance to get this implemented?
Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions