Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 2816853

Browse files
feat(queryconfig): Add scope to query extension for test
By adding ":scope >" to the css selector we avoid returning duplicate results if anybody wants to extend this test in the future.
1 parent e7b9f06 commit 2816853

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎src/__node_tests__/index.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ test('works with a custom configured element query for shadow dom elements', asy
131131

132132
// Given I have a naive query that allows searching shadow dom
133133
const queryMeAndChildrenAndShadow = (element, query) => [
134-
...element.querySelectorAll(query),
134+
...element.querySelectorAll(`:scope > ${query}`),
135135
...[...element.children].reduce(
136136
(result, child) => [
137137
...result,

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /