mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
2 lines
5.5 KiB
JavaScript
2 lines
5.5 KiB
JavaScript
|
/*! For license information please see 04da07e9.f0dc28c3.js.LICENSE.txt */
|
||
|
"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[20276],{35122:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>l,contentTitle:()=>o,default:()=>p,frontMatter:()=>s,metadata:()=>c,toc:()=>a});var i=t(85893),r=t(11151);const s={sidebar_label:"FrameWaitForFunctionOptions"},o="FrameWaitForFunctionOptions interface",c={id:"api/puppeteer.framewaitforfunctionoptions",title:"FrameWaitForFunctionOptions interface",description:"Signature:",source:"@site/../docs/api/puppeteer.framewaitforfunctionoptions.md",sourceDirName:"api",slug:"/api/puppeteer.framewaitforfunctionoptions",permalink:"/next/api/puppeteer.framewaitforfunctionoptions",draft:!1,unlisted:!1,tags:[],version:"current",frontMatter:{sidebar_label:"FrameWaitForFunctionOptions"},sidebar:"api",previous:{title:"FrameEvents",permalink:"/next/api/puppeteer.frameevents"},next:{title:"GeolocationOptions",permalink:"/next/api/puppeteer.geolocationoptions"}},l={},a=[{value:"Signature:",id:"signature",level:4},{value:"Properties",id:"properties",level:2}];function d(e){const n={a:"a",code:"code",h1:"h1",h2:"h2",h4:"h4",li:"li",p:"p",pre:"pre",ul:"ul",...(0,r.a)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(n.h1,{id:"framewaitforfunctionoptions-interface",children:"FrameWaitForFunctionOptions interface"}),"\n",(0,i.jsx)(n.h4,{id:"signature",children:"Signature:"}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-typescript",children:"export interface FrameWaitForFunctionOptions\n"})}),"\n",(0,i.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,i.jsxs)("table",{children:[(0,i.jsx)("thead",{children:(0,i.jsxs)("tr",{children:[(0,i.jsx)("th",{children:(0,i.jsx)(n.p,{children:"Property"})}),(0,i.jsx)("th",{children:(0,i.jsx)(n.p,{children:"Modifiers"})}),(0,i.jsx)("th",{children:(0,i.jsx)(n.p,{children:"Type"})}),(0,i.jsx)("th",{children:(0,i.jsx)(n.p,{children:"Description"})}),(0,i.jsx)("th",{children:(0,i.jsx)(n.p,{children:"Default"})})]})}),(0,i.jsxs)("tbody",{children:[(0,i.jsxs)("tr",{children:[(0,i.jsx)("td",{children:(0,i.jsx)(n.p,{children:"polling"})}),(0,i.jsx)("td",{children:(0,i.jsx)(n.p,{children:(0,i.jsx)(n.code,{children:"optional"})})}),(0,i.jsx)("td",{children:(0,i.jsx)(n.p,{children:"'raf' | 'mutation' | number"})}),(0,i.jsxs)("td",{children:[(0,i.jsxs)(n.p,{children:["An interval at which the ",(0,i.jsx)(n.code,{children:"pageFunction"})," is executed, defaults to ",(0,i.jsx)(n.code,{children:"raf"}),". If ",(0,i.jsx)(n.code,{children:"polling"})," is a number, then it is treated as an interval in milliseconds at which the function would be executed. If ",(0,i.jsx)(n.code,{children:"polling"})," is a string, then it can be one of the following values:"]}),(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsxs)(n.li,{children:["\n",(0,i.jsxs)(n.p,{children:[(0,i.jsx)(n.code,{children:"raf"})," - to constantly execute ",(0,i.jsx)(n.code,{children:"pageFunction"})," in ",(0,i.jsx)(n.code,{children:"requestAnimationFrame"})," callback. This is the tightest polling mode which is suitable to observe styling changes."]}),"\n"]}),"\n",(0,i.jsxs)(n.li,{children:["\n",(0,i.jsxs)(n.p,{children:[(0,i.jsx)(n.code,{children:"mutation"})," - to execute ",(0,i.jsx)(n.code,{children:"pageFunction"})," on every DOM mutation."]}),"\n"]}),"\n"]})]}),(0,i.jsx)("td",{})]}),(0,i.jsxs)("tr",{children:[(0,i.jsx)("td",{children:(0,i.jsx)(n.p,{children:"signal"})}),(0,i.jsx)("td",{children:(0,i.jsx)(n.p,{children:(0,i.jsx)(n.code,{children:"optional"})})}),(0,i.jsx)("td",{children:(0,i.jsx)(n.p,{children:"AbortSignal"})}),(0,i.jsx)("td",{children:(0,i.jsx)(n.p,{children:"A signal object that allows you to cancel a waitForFunction call."})}),(0,i.jsx)("td",{})]}),(0,i.jsxs)("tr",{children:[(0,i.jsx)("td",{children:(0,i.jsx)(n.p,{children:"timeout"})}),(0,i.jsx)("td",{children:(0,i.jsx)(n.p,{children:(0,i.jsx)(n.code,{children:"optional"})})}),(0,i.jsx)("td",{children:(0,i.jsx)(n.p,{children:"number"})}),(0,i.jsx)("td",{children:(0,i.jsxs)(n.p,{children:["Maximum time to wait in milliseconds. Defaults to ",(0,i.jsx)(n.code,{children:"30000"})
|