mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
2 lines
3.4 KiB
JavaScript
2 lines
3.4 KiB
JavaScript
|
/*! For license information please see 48265654.d7dcce9c.js.LICENSE.txt */
|
||
|
"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[61627],{88883:(e,r,s)=>{s.r(r),s.d(r,{assets:()=>p,contentTitle:()=>i,default:()=>d,frontMatter:()=>o,metadata:()=>a,toc:()=>c});var n=s(85893),t=s(11151);const o={sidebar_label:"Browser.version"},i="Browser.version() method",a={id:"api/puppeteer.browser.version",title:"Browser.version() method",description:"Gets a string representing this browser's name and version.",source:"@site/versioned_docs/version-22.0.0/api/puppeteer.browser.version.md",sourceDirName:"api",slug:"/api/puppeteer.browser.version",permalink:"/api/puppeteer.browser.version",draft:!1,unlisted:!1,tags:[],version:"22.0.0",frontMatter:{sidebar_label:"Browser.version"},sidebar:"api",previous:{title:"Browser.userAgent",permalink:"/api/puppeteer.browser.useragent"},next:{title:"Browser.waitForTarget",permalink:"/api/puppeteer.browser.waitfortarget"}},p={},c=[{value:"Signature:",id:"signature",level:4}];function l(e){const r={a:"a",code:"code",h1:"h1",h4:"h4",p:"p",pre:"pre",strong:"strong",...(0,t.a)(),...e.components};return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(r.h1,{id:"browserversion-method",children:"Browser.version() method"}),"\n",(0,n.jsxs)(r.p,{children:["Gets a string representing this ",(0,n.jsx)(r.a,{href:"/api/puppeteer.browser",children:"browser's"})," name and version."]}),"\n",(0,n.jsxs)(r.p,{children:["For headless browser, this is similar to ",(0,n.jsx)(r.code,{children:'"HeadlessChrome/61.0.3153.0"'}),". For non-headless or new-headless, this is similar to ",(0,n.jsx)(r.code,{children:'"Chrome/61.0.3153.0"'}),". For Firefox, it is similar to ",(0,n.jsx)(r.code,{children:'"Firefox/116.0a1"'}),"."]}),"\n",(0,n.jsxs)(r.p,{children:["The format of ",(0,n.jsx)(r.a,{href:"/api/puppeteer.browser.version",children:"Browser.version()"})," might change with future releases of browsers."]}),"\n",(0,n.jsx)(r.h4,{id:"signature",children:"Signature:"}),"\n",(0,n.jsx)(r.pre,{children:(0,n.jsx)(r.code,{className:"language-typescript",children:"class Browser {\n abstract version(): Promise<string>;\n}\n"})}),"\n",(0,n.jsx)(r.p,{children:(0,n.jsx)(r.strong,{children:"Returns:"})}),"\n",(0,n.jsx)(r.p,{children:"Promise<string>"})]})}function d(e={}){const{wrapper:r}={...(0,t.a)(),...e.components};return r?(0,n.jsx)(r,{...e,children:(0,n.jsx)(l,{...e})}):l(e)}},75251:(e,r,s)=>{var n=s(67294),t=Symbol.for("react.element"),o=Symbol.for("react.fragment"),i=Object.prototype.hasOwnProperty,a=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,p={key:!0,ref:!0,__self:!0,__source:!0};function c(e,r,s){var n,o={},c=null,l=null;for(n in void 0!==s&&(c=""+s),void 0!==r.key&&(c=""+r.key),void 0!==r.ref&&(l=r.ref),r)i.call(r,n)&&!p.hasOwnProperty(n)&&(o[n]=r[n]);if(e&&e.defaultProps)for(n in r=e.defaultProps)void 0===o[n]&&(o[n]=r[n]);return{$$typeof:t,type:e,key:c,ref:l,props:o,_owner:a.current}}r.Fragment=o,r.jsx=c,r.jsxs=c},85893:(e,r,s)=>{e.exports=s(75251)},11151:(e,r,s)=>{s.d(r,{Z:()=>a,a:()=>i});var n=s(67294);const t={},o=n.createContext(t);function i(e){const r=n.useContext(o);return n.useMemo((function(){return"function"==typeof e?e(r):{...r,...e}}),[r,e])}function a(e){let r;return r=e.disableParentContext?"function"==typeof e.components?e.components(t):e.components||t:i(e.components),n.createElement(o.Provider,{value:r},e.children)}}}]);
|