mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
2 lines
6.6 KiB
JavaScript
2 lines
6.6 KiB
JavaScript
/*! For license information please see 0f5160ac.bae1add6.js.LICENSE.txt */
|
|
"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[41302],{10354:(e,t,r)=>{r.r(t),r.d(t,{assets:()=>c,contentTitle:()=>o,default:()=>x,frontMatter:()=>n,metadata:()=>d,toc:()=>l});var i=r(85893),s=r(11151);const n={sidebar_label:"Cookie"},o="Cookie interface",d={id:"api/puppeteer.cookie",title:"Cookie interface",description:"Represents a cookie object.",source:"@site/../docs/api/puppeteer.cookie.md",sourceDirName:"api",slug:"/api/puppeteer.cookie",permalink:"/next/api/puppeteer.cookie",draft:!1,unlisted:!1,tags:[],version:"current",frontMatter:{sidebar_label:"Cookie"},sidebar:"api",previous:{title:"ContinueRequestOverrides",permalink:"/next/api/puppeteer.continuerequestoverrides"},next:{title:"CookieParam",permalink:"/next/api/puppeteer.cookieparam"}},c={},l=[{value:"Signature:",id:"signature",level:4},{value:"Properties",id:"properties",level:2}];function h(e){const t={a:"a",code:"code",h1:"h1",h2:"h2",h4:"h4",p:"p",pre:"pre",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,s.a)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(t.h1,{id:"cookie-interface",children:"Cookie interface"}),"\n",(0,i.jsx)(t.p,{children:"Represents a cookie object."}),"\n",(0,i.jsx)(t.h4,{id:"signature",children:"Signature:"}),"\n",(0,i.jsx)(t.pre,{children:(0,i.jsx)(t.code,{className:"language-typescript",children:"export interface Cookie\n"})}),"\n",(0,i.jsx)(t.h2,{id:"properties",children:"Properties"}),"\n",(0,i.jsxs)(t.table,{children:[(0,i.jsx)(t.thead,{children:(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.th,{children:"Property"}),(0,i.jsx)(t.th,{children:"Modifiers"}),(0,i.jsx)(t.th,{children:"Type"}),(0,i.jsx)(t.th,{children:"Description"}),(0,i.jsx)(t.th,{children:"Default"})]})}),(0,i.jsxs)(t.tbody,{children:[(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:"domain"}),(0,i.jsx)(t.td,{}),(0,i.jsx)(t.td,{children:"string"}),(0,i.jsx)(t.td,{children:"Cookie domain."}),(0,i.jsx)(t.td,{})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:"expires"}),(0,i.jsx)(t.td,{}),(0,i.jsx)(t.td,{children:"number"}),(0,i.jsxs)(t.td,{children:["Cookie expiration date as the number of seconds since the UNIX epoch. Set to ",(0,i.jsx)("code",{children:"-1"})," for session cookies"]}),(0,i.jsx)(t.td,{})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:"httpOnly"}),(0,i.jsx)(t.td,{}),(0,i.jsx)(t.td,{children:"boolean"}),(0,i.jsx)(t.td,{children:"True if cookie is http-only."}),(0,i.jsx)(t.td,{})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:"name"}),(0,i.jsx)(t.td,{}),(0,i.jsx)(t.td,{children:"string"}),(0,i.jsx)(t.td,{children:"Cookie name."}),(0,i.jsx)(t.td,{})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:"partitionKey"}),(0,i.jsx)(t.td,{children:(0,i.jsx)("code",{children:"optional"})}),(0,i.jsx)(t.td,{children:"string"}),(0,i.jsx)(t.td,{children:"Cookie partition key. The site of the top-level URL the browser was visiting at the start of the request to the endpoint that set the cookie. Supported only in Chrome."}),(0,i.jsx)(t.td,{})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:"partitionKeyOpaque"}),(0,i.jsx)(t.td,{children:(0,i.jsx)("code",{children:"optional"})}),(0,i.jsx)(t.td,{children:"boolean"}),(0,i.jsx)(t.td,{children:"True if cookie partition key is opaque. Supported only in Chrome."}),(0,i.jsx)(t.td,{})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:"path"}),(0,i.jsx)(t.td,{}),(0,i.jsx)(t.td,{children:"string"}),(0,i.jsx)(t.td,{children:"Cookie path."}),(0,i.jsx)(t.td,{})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:"priority"}),(0,i.jsx)(t.td,{children:(0,i.jsx)("code",{children:"optional"})}),(0,i.jsx)(t.td,{children:(0,i.jsx)(t.a,{href:"/next/api/puppeteer.cookiepriority",children:"CookiePriority"})}),(0,i.jsx)(t.td,{children:"Cookie Priority. Supported only in Chrome."}),(0,i.jsx)(t.td,{})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:"sameParty"}),(0,i.jsx)(t.td,{children:(0,i.jsx)("code",{children:"optional"})}),(0,i.jsx)(t.td,{children:"boolean"}),(0,i.jsx)(t.td,{children:"True if cookie is SameParty. Supported only in Chrome."}),(0,i.jsx)(t.td,{})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:"sameSite"}),(0,i.jsx)(t.td,{children:(0,i.jsx)("code",{children:"optional"})}),(0,i.jsx)(t.td,{children:(0,i.jsx)(t.a,{href:"/next/api/puppeteer.cookiesamesite",children:"CookieSameSite"})}),(0,i.jsx)(t.td,{children:"Cookie SameSite type."}),(0,i.jsx)(t.td,{})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:"secure"}),(0,i.jsx)(t.td,{}),(0,i.jsx)(t.td,{children:"boolean"}),(0,i.jsx)(t.td,{children:"True if cookie is secure."}),(0,i.jsx)(t.td,{})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:"session"}),(0,i.jsx)(t.td,{}),(0,i.jsx)(t.td,{children:"boolean"}),(0,i.jsx)(t.td,{children:"True in case of session cookie."}),(0,i.jsx)(t.td,{})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:"size"}),(0,i.jsx)(t.td,{}),(0,i.jsx)(t.td,{children:"number"}),(0,i.jsx)(t.td,{children:"Cookie size."}),(0,i.jsx)(t.td,{})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:"sourceScheme"}),(0,i.jsx)(t.td,{children:(0,i.jsx)("code",{children:"optional"})}),(0,i.jsx)(t.td,{children:(0,i.jsx)(t.a,{href:"/next/api/puppeteer.cookiesourcescheme",children:"CookieSourceScheme"})}),(0,i.jsx)(t.td,{children:"Cookie source scheme type. Supported only in Chrome."}),(0,i.jsx)(t.td,{})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:"value"}),(0,i.jsx)(t.td,{}),(0,i.jsx)(t.td,{children:"string"}),(0,i.jsx)(t.td,{children:"Cookie value."}),(0,i.jsx)(t.td,{})]})]})]})]})}function x(e={}){const{wrapper:t}={...(0,s.a)(),...e.components};return t?(0,i.jsx)(t,{...e,children:(0,i.jsx)(h,{...e})}):h(e)}},75251:(e,t,r)=>{var i=r(67294),s=Symbol.for("react.element"),n=Symbol.for("react.fragment"),o=Object.prototype.hasOwnProperty,d=i.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,c={key:!0,ref:!0,__self:!0,__source:!0};function l(e,t,r){var i,n={},l=null,h=null;for(i in void 0!==r&&(l=""+r),void 0!==t.key&&(l=""+t.key),void 0!==t.ref&&(h=t.ref),t)o.call(t,i)&&!c.hasOwnProperty(i)&&(n[i]=t[i]);if(e&&e.defaultProps)for(i in t=e.defaultProps)void 0===n[i]&&(n[i]=t[i]);return{$$typeof:s,type:e,key:l,ref:h,props:n,_owner:d.current}}t.Fragment=n,t.jsx=l,t.jsxs=l},85893:(e,t,r)=>{e.exports=r(75251)},11151:(e,t,r)=>{r.d(t,{Z:()=>d,a:()=>o});var i=r(67294);const s={},n=i.createContext(s);function o(e){const t=i.useContext(n);return i.useMemo((function(){return"function"==typeof e?e(t):{...t,...e}}),[t,e])}function d(e){let t;return t=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:o(e.components),i.createElement(n.Provider,{value:t},e.children)}}}]); |