"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[16353],{3905:(e,t,n)=>{n.d(t,{Zo:()=>c,kt:()=>d});vara=n(67294);functiono(e,t,n){returntine?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}functionr(e,t){varn=Object.keys(e);if(Object.getOwnPropertySymbols){vara=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){returnObject.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}returnn}functionl(e){for(vart=1;t<arguments.length;t++){varn=null!=arguments[t]?arguments[t]:{};t%2?r(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}returne}functioni(e,t){if(null==e)return{};varn,a,o=function(e,t){if(null==e)return{};varn,a,o={},r=Object.keys(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||(o[n]=e[n]);returno}(e,t);if(Object.getOwnPropertySymbols){varr=Object.getOwnPropertySymbols(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}returno}vars=a.createContext({}),p=function(e){vart=a.useContext(s),n=t;returne&&(n="function"==typeofe?e(t):l(l({},t),e)),n},c=function(e){vart=p(e.components);returna.createElement(s.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){vart=e.children;returna.createElement(a.Fragment,{},t)}},m=a.forwardRef((function(e,t){varn=e.components,o=e.mdxType,r=e.originalType,s=e.parentName,c=i(e,["components","mdxType","originalType","parentName"]),m=p(n),d=o,h=m["".concat(s,".").concat(d)]||m[d]||u[d]||r;returnn?a.createElement(h,l(l({ref:t},c),{},{components:n})):a.createElement(h,l({ref:t},c))}));functiond(e,t){varn=arguments,o=t&&t.mdxType;if("string"==typeofe||o){varr=n.length,l=newArray(r);l[0]=m;vari={};for(varsint)hasOwnProperty.call(t,s)&&(i[s]=t[s]);i.originalType=e,i.mdxType="string"==typeofe?e:o,l[1]=i;for(varp=2;p<r;p++)l[p]=n[p];returna.createElement.apply(null,l)}returna.createElement.apply(null,n)}m.displayName="MDXCreateElement"},58455:(e,t,n)=>{n.r(t),n.d(t,{assets:()=>p,contentTitle:()=>i,default:()=>m,frontMatter:()=>l,metadata:()=>s,toc:()=>c});n(67294);vara=n(3905);functiono(){returno=Object.assign||function(e){for(vart=1;t<arguments.length;t++){varn=arguments[t];for(varainn)Object.prototype.hasOwnProperty.call(n,a)&&(e[a]=n[a])}returne},o.apply(this,arguments)}functionr(e,t){if(null==e)return{};varn,a,o=function(e,t){if(null==e)return{};varn,a,o={},r=Object.keys(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||(o[n]=e[n]);returno}(e,t);if(Object.getOwnPropertySymbols){varr=Object.getOwnPropertySymbols(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}returno}constl={},i="Query Selectors",s={unversionedId:"guides/query-selectors",id:"version-20.1.0/guides/query-selectors",title:"Query Selectors",description:"Queries are the primary mechanism for interacting with the DOM on your site. For example, a typical workflow goes like:",source:"@site/versioned_docs/version-20.1.0/guides/query-selectors.md",sourceDirName:"guides",slug:"/guides/query-selectors",permalink:"/guides/query-selectors",draft:!1,tags:[],version:"20.1.0",frontMatter:{},sidebar:"docs",previous:{title:"Configuration",permalink:"/guides/configuration"},next:{title:"Evaluate JavaScript",permalink:"/guides/evaluate-javascript"}},p={},c=[{value:"<code>P</code> Selectors",id:"p-selectors",level:2},{value:"<code>>>></code> and <code>>>>></code> combinators",id:"-and--combinators",level:3},{value:"Example",id:"example",level:4},{value:"<code>P</code>-elements",id:"p-elements",level:3},{value:"Text selectors (<code>-p-text</code>)",id:"text-selectors--p-text",level:4},{value:"Example",id:"example-1",level:5},{value:"XPath selectors (<code>-p-xpath</code>)",id:"xpath-selectors--p-xpath",level:4},{value:"Example",id:"example-2",level:5}