Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs(new): migrate HTTPResponse docs to TSDoc #6085

Merged
merged 2 commits into from Jun 25, 2020
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
22 changes: 0 additions & 22 deletions new-docs/puppeteer.httpresponse._constructor_.md

This file was deleted.

22 changes: 0 additions & 22 deletions new-docs/puppeteer.httpresponse._resolvebody.md

This file was deleted.

2 changes: 2 additions & 0 deletions new-docs/puppeteer.httpresponse.buffer.md
Expand Up @@ -13,3 +13,5 @@ buffer(): Promise<Buffer>;

Promise&lt;Buffer&gt;

Promise which resolves to a buffer with response body.

2 changes: 2 additions & 0 deletions new-docs/puppeteer.httpresponse.frame.md
Expand Up @@ -13,3 +13,5 @@ frame(): Frame | null;

[Frame](./puppeteer.frame.md) \| null

A [Frame](./puppeteer.frame.md) that initiated this response, or `null` if navigating to error pages.

2 changes: 2 additions & 0 deletions new-docs/puppeteer.httpresponse.fromcache.md
Expand Up @@ -13,3 +13,5 @@ fromCache(): boolean;

boolean

True if the response was served from either the browser's disk cache or memory cache.

2 changes: 2 additions & 0 deletions new-docs/puppeteer.httpresponse.fromserviceworker.md
Expand Up @@ -13,3 +13,5 @@ fromServiceWorker(): boolean;

boolean

True if the response was served by a service worker.

2 changes: 2 additions & 0 deletions new-docs/puppeteer.httpresponse.headers.md
Expand Up @@ -13,3 +13,5 @@ headers(): Record<string, string>;

Record&lt;string, string&gt;

An object with HTTP headers associated with the response. All header names are lower-case.

6 changes: 6 additions & 0 deletions new-docs/puppeteer.httpresponse.json.md
Expand Up @@ -13,3 +13,9 @@ json(): Promise<any>;

Promise&lt;any&gt;

Promise which resolves to a JSON representation of response body.

## Remarks

This method will throw if the response body is not parsable via `JSON.parse`<!-- -->.

9 changes: 4 additions & 5 deletions new-docs/puppeteer.httpresponse.md
Expand Up @@ -4,23 +4,22 @@

## HTTPResponse class

The HTTPResponse class represents responses which are received by page.

<b>Signature:</b>

```typescript
export declare class HTTPResponse
```

## Constructors
## Remarks

| Constructor | Modifiers | Description |
| --- | --- | --- |
| [(constructor)(client, request, responsePayload)](./puppeteer.httpresponse._constructor_.md) | | Constructs a new instance of the <code>HTTPResponse</code> class |
The constructor for this class is marked as internal. Third-party code should not call the constructor directly or create subclasses that extend the `HTTPResponse` class.

## Methods

| Method | Modifiers | Description |
| --- | --- | --- |
| [\_resolveBody(err)](./puppeteer.httpresponse._resolvebody.md) | | |
| [buffer()](./puppeteer.httpresponse.buffer.md) | | |
| [frame()](./puppeteer.httpresponse.frame.md) | | |
| [fromCache()](./puppeteer.httpresponse.fromcache.md) | | |
Expand Down
2 changes: 2 additions & 0 deletions new-docs/puppeteer.httpresponse.ok.md
Expand Up @@ -13,3 +13,5 @@ ok(): boolean;

boolean

True if the response was successful (status in the range 200-299).

4 changes: 3 additions & 1 deletion new-docs/puppeteer.httpresponse.remoteaddress.md
Expand Up @@ -11,5 +11,7 @@ remoteAddress(): RemoteAddress;
```
<b>Returns:</b>

RemoteAddress
[RemoteAddress](./puppeteer.remoteaddress.md)

The IP address and port number used to connect to the remote server.

2 changes: 2 additions & 0 deletions new-docs/puppeteer.httpresponse.request.md
Expand Up @@ -13,3 +13,5 @@ request(): HTTPRequest;

[HTTPRequest](./puppeteer.httprequest.md)

A matching [HTTPRequest](./puppeteer.httprequest.md) object.

2 changes: 2 additions & 0 deletions new-docs/puppeteer.httpresponse.securitydetails.md
Expand Up @@ -13,3 +13,5 @@ securityDetails(): SecurityDetails | null;

[SecurityDetails](./puppeteer.securitydetails.md) \| null

[SecurityDetails](./puppeteer.securitydetails.md) if the response was received over the secure connection, or `null` otherwise.

2 changes: 2 additions & 0 deletions new-docs/puppeteer.httpresponse.status.md
Expand Up @@ -13,3 +13,5 @@ status(): number;

number

The status code of the response (e.g., 200 for a success).

2 changes: 2 additions & 0 deletions new-docs/puppeteer.httpresponse.statustext.md
Expand Up @@ -13,3 +13,5 @@ statusText(): string;

string

The status text of the response (e.g. usually an "OK" for a success).

2 changes: 2 additions & 0 deletions new-docs/puppeteer.httpresponse.text.md
Expand Up @@ -13,3 +13,5 @@ text(): Promise<string>;

Promise&lt;string&gt;

Promise which resolves to a text representation of response body.

2 changes: 2 additions & 0 deletions new-docs/puppeteer.httpresponse.url.md
Expand Up @@ -13,3 +13,5 @@ url(): string;

string

The URL of the response.

3 changes: 2 additions & 1 deletion new-docs/puppeteer.md
Expand Up @@ -24,7 +24,7 @@
| [Frame](./puppeteer.frame.md) | |
| [FrameManager](./puppeteer.framemanager.md) | |
| [HTTPRequest](./puppeteer.httprequest.md) | |
| [HTTPResponse](./puppeteer.httpresponse.md) | |
| [HTTPResponse](./puppeteer.httpresponse.md) | The HTTPResponse class represents responses which are received by page. |
| [JSHandle](./puppeteer.jshandle.md) | |
| [Keyboard](./puppeteer.keyboard.md) | |
| [Mouse](./puppeteer.mouse.md) | |
Expand Down Expand Up @@ -55,6 +55,7 @@
| [KeyDefinition](./puppeteer.keydefinition.md) | Copyright 2017 Google Inc. All rights reserved.<!-- -->Licensed under the Apache License, Version 2.0 (the 'License'); you may not use this file except in compliance with the License. You may obtain a copy of the License at<!-- -->http://www.apache.org/licenses/LICENSE-2.0<!-- -->Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an 'AS IS' BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. |
| [Metrics](./puppeteer.metrics.md) | |
| [PressOptions](./puppeteer.pressoptions.md) | |
| [RemoteAddress](./puppeteer.remoteaddress.md) | |
| [SerializedAXNode](./puppeteer.serializedaxnode.md) | Represents a Node and the properties of it that are relevant to Accessibility. |
| [SnapshotOptions](./puppeteer.snapshotoptions.md) | |
| [WaitForTargetOptions](./puppeteer.waitfortargetoptions.md) | |
Expand Down
11 changes: 11 additions & 0 deletions new-docs/puppeteer.remoteaddress.ip.md
@@ -0,0 +1,11 @@
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [puppeteer](./puppeteer.md) &gt; [RemoteAddress](./puppeteer.remoteaddress.md) &gt; [ip](./puppeteer.remoteaddress.ip.md)

## RemoteAddress.ip property

<b>Signature:</b>

```typescript
ip: string;
```
20 changes: 20 additions & 0 deletions new-docs/puppeteer.remoteaddress.md
@@ -0,0 +1,20 @@
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [puppeteer](./puppeteer.md) &gt; [RemoteAddress](./puppeteer.remoteaddress.md)

## RemoteAddress interface


<b>Signature:</b>

```typescript
export interface RemoteAddress
```

## Properties

| Property | Type | Description |
| --- | --- | --- |
| [ip](./puppeteer.remoteaddress.ip.md) | string | |
| [port](./puppeteer.remoteaddress.port.md) | number | |

11 changes: 11 additions & 0 deletions new-docs/puppeteer.remoteaddress.port.md
@@ -0,0 +1,11 @@
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [puppeteer](./puppeteer.md) &gt; [RemoteAddress](./puppeteer.remoteaddress.md) &gt; [port](./puppeteer.remoteaddress.port.md)

## RemoteAddress.port property

<b>Signature:</b>

```typescript
port: number;
```