mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
2 lines
4.1 KiB
JavaScript
2 lines
4.1 KiB
JavaScript
/*! For license information please see bdaf2732.8d880cf7.js.LICENSE.txt */
|
|
"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[50816],{85220:(e,t,n)=>{n.r(t),n.d(t,{assets:()=>a,contentTitle:()=>i,default:()=>u,frontMatter:()=>s,metadata:()=>c,toc:()=>p});var r=n(85893),o=n(11151);const s={sidebar_label:"BrowserContext.isIncognito"},i="BrowserContext.isIncognito() method",c={id:"api/puppeteer.browsercontext.isincognito",title:"BrowserContext.isIncognito() method",description:"Warning: This API is now obsolete.",source:"@site/../docs/api/puppeteer.browsercontext.isincognito.md",sourceDirName:"api",slug:"/api/puppeteer.browsercontext.isincognito",permalink:"/next/api/puppeteer.browsercontext.isincognito",draft:!1,unlisted:!1,tags:[],version:"current",frontMatter:{sidebar_label:"BrowserContext.isIncognito"},sidebar:"api",previous:{title:"BrowserContext.close",permalink:"/next/api/puppeteer.browsercontext.close"},next:{title:"BrowserContext.newPage",permalink:"/next/api/puppeteer.browsercontext.newpage"}},a={},p=[{value:"Signature:",id:"signature",level:4}];function l(e){const t={a:"a",blockquote:"blockquote",code:"code",h1:"h1",h4:"h4",p:"p",pre:"pre",strong:"strong",...(0,o.a)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(t.h1,{id:"browsercontextisincognito-method",children:"BrowserContext.isIncognito() method"}),"\n",(0,r.jsxs)(t.blockquote,{children:["\n",(0,r.jsx)(t.p,{children:"Warning: This API is now obsolete."}),"\n",(0,r.jsxs)(t.p,{children:["In Chrome, the ",(0,r.jsx)(t.a,{href:"/next/api/puppeteer.browser.defaultbrowsercontext",children:"default browser context"}),' can also be "incognito" if configured via the arguments and in such cases this getter returns wrong results (see ',(0,r.jsx)(t.a,{href:"https://github.com/puppeteer/puppeteer/issues/8836",children:"https://github.com/puppeteer/puppeteer/issues/8836"}),'). Also, the term "incognito" is not applicable to other browsers. To migrate, check the ',(0,r.jsx)(t.a,{href:"/next/api/puppeteer.browser.defaultbrowsercontext",children:"default browser context"})," instead: in Chrome all non-default contexts are incognito, and the default context might be incognito if you provide the ",(0,r.jsx)(t.code,{children:"--incognito"})," argument when launching the browser."]}),"\n"]}),"\n",(0,r.jsxs)(t.p,{children:["Whether this ",(0,r.jsx)(t.a,{href:"/next/api/puppeteer.browsercontext",children:"browser context"})," is incognito."]}),"\n",(0,r.jsxs)(t.p,{children:["In Chrome, the ",(0,r.jsx)(t.a,{href:"/next/api/puppeteer.browser.defaultbrowsercontext",children:"default browser context"})," is the only non-incognito browser context."]}),"\n",(0,r.jsx)(t.h4,{id:"signature",children:"Signature:"}),"\n",(0,r.jsx)(t.pre,{children:(0,r.jsx)(t.code,{className:"language-typescript",children:"class BrowserContext {\n abstract isIncognito(): boolean;\n}\n"})}),"\n",(0,r.jsx)(t.p,{children:(0,r.jsx)(t.strong,{children:"Returns:"})}),"\n",(0,r.jsx)(t.p,{children:"boolean"})]})}function u(e={}){const{wrapper:t}={...(0,o.a)(),...e.components};return t?(0,r.jsx)(t,{...e,children:(0,r.jsx)(l,{...e})}):l(e)}},75251:(e,t,n)=>{var r=n(67294),o=Symbol.for("react.element"),s=Symbol.for("react.fragment"),i=Object.prototype.hasOwnProperty,c=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};function p(e,t,n){var r,s={},p=null,l=null;for(r in void 0!==n&&(p=""+n),void 0!==t.key&&(p=""+t.key),void 0!==t.ref&&(l=t.ref),t)i.call(t,r)&&!a.hasOwnProperty(r)&&(s[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps)void 0===s[r]&&(s[r]=t[r]);return{$$typeof:o,type:e,key:p,ref:l,props:s,_owner:c.current}}t.Fragment=s,t.jsx=p,t.jsxs=p},85893:(e,t,n)=>{e.exports=n(75251)},11151:(e,t,n)=>{n.d(t,{Z:()=>c,a:()=>i});var r=n(67294);const o={},s=r.createContext(o);function i(e){const t=r.useContext(s);return r.useMemo((function(){return"function"==typeof e?e(t):{...t,...e}}),[t,e])}function c(e){let t;return t=e.disableParentContext?"function"==typeof e.components?e.components(o):e.components||o:i(e.components),r.createElement(s.Provider,{value:t},e.children)}}}]); |