mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
feat(Targets): expose browser target (#2036)
This patch exposes "browser" target to the list of targets.
This commit is contained in:
@@ -229,11 +229,11 @@ class Target {
|
||||
}
|
||||
|
||||
/**
|
||||
* @return {"page"|"service_worker"|"other"}
|
||||
* @return {"page"|"service_worker"|"other"|"browser"}
|
||||
*/
|
||||
type() {
|
||||
const type = this._targetInfo.type;
|
||||
if (type === 'page' || type === 'service_worker')
|
||||
if (type === 'page' || type === 'service_worker' || type === 'browser')
|
||||
return type;
|
||||
return 'other';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user