"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[30138],{3905:(e,t,a)=>{a.d(t,{Zo:()=>u,kt:()=>m});varr=a(67294);functionn(e,t,a){returntine?Object.defineProperty(e,t,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[t]=a,e}functioni(e,t){vara=Object.keys(e);if(Object.getOwnPropertySymbols){varr=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){returnObject.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}returna}functiono(e){for(vart=1;t<arguments.length;t++){vara=null!=arguments[t]?arguments[t]:{};t%2?i(Object(a),!0).forEach((function(t){n(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):i(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}returne}functionp(e,t){if(null==e)return{};vara,r,n=function(e,t){if(null==e)return{};vara,r,n={},i=Object.keys(e);for(r=0;r<i.length;r++)a=i[r],t.indexOf(a)>=0||(n[a]=e[a]);returnn}(e,t);if(Object.getOwnPropertySymbols){vari=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)a=i[r],t.indexOf(a)>=0||Object.prototype.propertyIsEnumerable.call(e,a)&&(n[a]=e[a])}returnn}varl=r.createContext({}),s=function(e){vart=r.useContext(l),a=t;returne&&(a="function"==typeofe?e(t):o(o({},t),e)),a},u=function(e){vart=s(e.components);returnr.createElement(l.Provider,{value:t},e.children)},c={inlineCode:"code",wrapper:function(e){vart=e.children;returnr.createElement(r.Fragment,{},t)}},g=r.forwardRef((function(e,t){vara=e.components,n=e.mdxType,i=e.originalType,l=e.parentName,u=p(e,["components","mdxType","originalType","parentName"]),g=s(a),m=n,d=g["".concat(l,".").concat(m)]||g[m]||c[m]||i;returna?r.createElement(d,o(o({ref:t},u),{},{components:a})):r.createElement(d,o({ref:t},u))}));functionm(e,t){vara=arguments,n=t&&t.mdxType;if("string"==typeofe||n){vari=a.length,o=newArray(i);o[0]=g;varp={};for(varlint)hasOwnProperty.call(t,l)&&(p[l]=t[l]);p.originalType=e,p.mdxType="string"==typeofe?e:n,o[1]=p;for(vars=2;s<i;s++)o[s]=a[s];returnr.createElement.apply(null,o)}returnr.createElement.apply(null,a)}g.displayName="MDXCreateElement"},29610:(e,t,a)=>{a.r(t),a.d(t,{assets:()=>l,contentTitle:()=>o,default:()=>c,frontMatter:()=>i,metadata:()=>p,toc:()=>s});varr=a(87462),n=(a(67294),a(3905));consti={sidebar_label:"Page.waitForNavigation"},o="Page.waitForNavigation() method",p={unversionedId:"api/puppeteer.page.waitfornavigation",id:"version-16.2.0/api/puppeteer.page.waitfornavigation",title:"Page.waitForNavigation() method",description:"Waits for the page to navigate to a new URL or to reload. It is useful when you run code that will indirectly cause the page to navigate.",source:"@site/versioned_docs/version-16.2.0/api/puppeteer.page.waitfornavigation.md",sourceDirName:"api",slug:"/api/puppeteer.page.waitfornavigation",permalink:"/api/puppeteer.page.waitfornavigation",draft:!1,tags:[],version:"16.2.0",frontMatter:{sidebar_label:"Page.waitForNavigation"},sidebar:"sidebar",previous:{title:"Page.waitForFunction",permalink:"/api/puppeteer.page.waitforfunction"},next:{title:"Page.waitForNetworkIdle",permalink:"/api/puppeteer.page.waitfornetworkidle"}},l={},s=[{value:"Parameters",id:"parameters",level:2},{value:"Remarks",id:"remarks",level:2},{value:"Example",id:"example",level:2}],u={toc:s};functionc(e){let{components:t,...a}=e;return(0,n.kt)("wrapper",(0,r.Z)({},u,a,{components:t,mdxType:"MDXLayout"}),(0,n.kt)("h1",{id:"pagewaitfornavigation-method"},"Page.waitForNavigation() method"),(0,n.kt)("p",null,"Waits for the page to navigate to a new URL or to reload. It is useful when you run code that will indirectly cause the page to navigate."),(0,n.kt)("p",null,(0,n.kt)("strong",{parentName:"p"},"Signature:")),(0,n.kt)("pre",null,(0,n.kt)("code",{parentName:"pre",className:"language-typescript"},"class Page {\n waitForNavigation(options?: WaitForOptions): Promise<HTTPResponse | null>;\n}\n")),(0,n.kt)("h2",{id:"parameters"},"Parameters"),(0,n.kt)("table",null,(0,n.kt)("thead",{parentName:"table"},(0,n