Skip to content

Commit

Permalink
feat: export Frame._client through getter
Browse files Browse the repository at this point in the history
  • Loading branch information
jrandolf committed Feb 21, 2022
1 parent 131924f commit 79c980f
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/common/FrameManager.ts
Expand Up @@ -702,6 +702,11 @@ export class Frame {
);
}

/**
* @remarks
*
* @returns `true` if the frame is an OOP frame, or `false` otherwise.
*/
isOOPFrame(): boolean {
return this._client !== this._frameManager._client;
}
Expand Down Expand Up @@ -785,6 +790,13 @@ export class Frame {
return await this._frameManager.waitForFrameNavigation(this, options);
}

/**
* @internal
*/
client(): CDPSession {
return this._client;
}

/**
* @returns a promise that resolves to the frame's default execution context.
*/
Expand Down
1 change: 1 addition & 0 deletions utils/doclint/check_public_api/index.js
Expand Up @@ -24,6 +24,7 @@ const {

const EXCLUDE_PROPERTIES = new Set([
'Browser.create',
'Frame.client',
'Headers.fromPayload',
'Page.client',
'Page.create',
Expand Down

0 comments on commit 79c980f

Please sign in to comment.