搜索 | 用户支持

防范以用户支持为名的诈骗。我们绝对不会要求您拨打电话或发送短信,及提供任何个人信息。请使用“举报滥用”选项报告涉及违规的行为。

详细了解

What syntax does the search feature in Developer tools use?

  • 1 个回答
  • 1 人有此问题
  • 1 次查看
  • 最后回复者为 user1929

more options

The search boxes in the inspector window window returns no results whenever I try to search for specific key-value pairs like: role="main".

I can only get results for main or role. Is there a search string parameter/syntax reference anywhere? I've searched high and low, but articles/references found in the documentation is VERY basic.

Thanks

The search boxes in the inspector window window returns no results whenever I try to search for specific key-value pairs like: role="main". I can only get results for main or role. Is there a search string parameter/syntax reference anywhere? I've searched high and low, but articles/references found in the documentation is VERY basic. Thanks

被采纳的解决方案

Hi,

I'm not aware of any documentation for it, although there might be something. As far as I can tell, you can typically just search for a string of text, but this won't work in some cases, like what you've found. You can also type CSS selectors to find elements, which works a lot better - for your example, you could use this CSS selector:

[role="main"]

Hope that helps!

定位到答案原位置 👍 1

所有回复 (1)

more options

选择的解决方案

Hi,

I'm not aware of any documentation for it, although there might be something. As far as I can tell, you can typically just search for a string of text, but this won't work in some cases, like what you've found. You can also type CSS selectors to find elements, which works a lot better - for your example, you could use this CSS selector:

[role="main"]

Hope that helps!