Skip to content

Commit 4d74440

Browse files
authored
9.0.2
1 parent b0ebcf5 commit 4d74440

File tree

2 files changed

+46
-25
lines changed

2 files changed

+46
-25
lines changed

Dockerfile

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,11 +48,11 @@ RUN apt-get -qq update \
4848
wget \
4949
xdg-utils \
5050
# ↑ https://github.com/puppeteer/puppeteer/blob/main/docs/troubleshooting.md#chrome-headless-doesnt-launch-on-unix
51-
# ↓ Added based on the information obtained from by console.log(line) at https://deno.land/x/puppeteer@9.0.1/src/deno/BrowserRunner.ts#L168.
51+
# ↓ Added based on the information obtained from by console.log(line) at https://deno.land/x/puppeteer@9.0.2/src/deno/BrowserRunner.ts#L168.
5252
libdrm2 \
5353
libxkbcommon0 \
5454
libxshmfence1 \
55-
# ↑ Added based on the information obtained from by console.log(line) at https://deno.land/x/puppeteer@9.0.1/src/deno/BrowserRunner.ts#L168.
55+
# ↑ Added based on the information obtained from by console.log(line) at https://deno.land/x/puppeteer@9.0.2/src/deno/BrowserRunner.ts#L168.
5656
&& curl -fsSL https://github.com/denoland/deno/releases/download/v${DENO_VERSION}/deno-x86_64-unknown-linux-gnu.zip \
5757
--output deno.zip \
5858
&& unzip deno.zip \
@@ -79,8 +79,8 @@ ENV DENO_DIR /deno-dir/
7979
WORKDIR /root
8080
COPY . .
8181

82-
# https://deno.land/x/puppeteer@9.0.1#installation
83-
# In your real script, replace the installation script with https://deno.land/x/puppeteer@9.0.1/install.ts
82+
# https://deno.land/x/puppeteer@9.0.2#installation
83+
# In your real script, replace the installation script with https://deno.land/x/puppeteer@9.0.2/install.ts
8484
RUN PUPPETEER_PRODUCT=chrome deno run -A --unstable ./install.ts
8585

8686
ENTRYPOINT ["deno"]

README.md

Lines changed: 42 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -2,18 +2,25 @@
22

33
<img src="./logo.png" height="200" align="right">
44

5-
###### [API](https://github.com/puppeteer/puppeteer/blob/v9.0.1/docs/api.md)
5+
###### [API](https://github.com/puppeteer/puppeteer/blob/v9.0.2/docs/api.md)
66

77
A fork of [Puppeteer](https://pptr.dev/) running on Deno.
88

9-
> Puppeteer is a library which provides a high-level API to control Chrome, Chromium, or Firefox Nightly over the DevTools Protocol. Puppeteer runs headless by default, but can be configured to run full (non-headless) Chrome or Chromium.
9+
> Puppeteer is a library which provides a high-level API to control Chrome,
10+
> Chromium, or Firefox Nightly over the DevTools Protocol. Puppeteer runs
11+
> headless by default, but can be configured to run full (non-headless) Chrome
12+
> or Chromium.
1013
11-
Most things that you can do manually in the browser can be done using Puppeteer! Here are a few examples to get you started:
14+
Most things that you can do manually in the browser can be done using Puppeteer!
15+
Here are a few examples to get you started:
1216

1317
- Generate screenshots and PDFs of pages.
14-
- Crawl a SPA (Single-Page Application) and generate pre-rendered content (i.e. "SSR" (Server-Side Rendering)).
18+
- Crawl a SPA (Single-Page Application) and generate pre-rendered content (i.e.
19+
"SSR" (Server-Side Rendering)).
1520
- Automate form submission, UI testing, keyboard input, etc.
16-
- Create an up-to-date, automated testing environment. Run your tests directly in the latest version of Chrome using the latest JavaScript and browser features.
21+
- Create an up-to-date, automated testing environment. Run your tests directly
22+
in the latest version of Chrome using the latest JavaScript and browser
23+
features.
1724
- Capture a timeline trace of your site to help diagnose performance issues.
1825
- Test Chrome Extensions.
1926

@@ -24,28 +31,35 @@ Most things that you can do manually in the browser can be done using Puppeteer!
2431
To use Puppeteer, import it like so:
2532

2633
```ts
27-
import puppeteer from "https://deno.land/x/puppeteer@9.0.1/mod.ts";
34+
import puppeteer from "https://deno.land/x/puppeteer@9.0.2/mod.ts";
2835
```
2936

30-
Puppeteer can use any recent version of Chromium or Firefox Nightly, but this version of Puppeteer is only validated against a specific version. To cache these versions in the Puppeteer cache, run the commands below.
37+
Puppeteer can use any recent version of Chromium or Firefox Nightly, but this
38+
version of Puppeteer is only validated against a specific version. To cache
39+
these versions in the Puppeteer cache, run the commands below.
3140

3241
```shell
33-
PUPPETEER_PRODUCT=chrome deno run -A --unstable https://deno.land/x/puppeteer@9.0.1/install.ts
34-
PUPPETEER_PRODUCT=firefox deno run -A --unstable https://deno.land/x/puppeteer@9.0.1/install.ts
42+
PUPPETEER_PRODUCT=chrome deno run -A --unstable https://deno.land/x/puppeteer@9.0.2/install.ts
43+
PUPPETEER_PRODUCT=firefox deno run -A --unstable https://deno.land/x/puppeteer@9.0.2/install.ts
3544
```
3645

37-
You can find all of the supported environment variables to customize installation [in the Puppeteer docs](https://pptr.dev/#?product=Puppeteer&version=v5.5.0&show=api-environment-variables).
46+
You can find all of the supported environment variables to customize
47+
installation
48+
[in the Puppeteer docs](https://pptr.dev/#?product=Puppeteer&version=v5.5.0&show=api-environment-variables).
3849

3950
### Usage
4051

41-
Puppeteer will be familiar to people using other browser testing frameworks. You create an instance of `Browser`, open pages, and then manipulate them with Puppeteer's API.
52+
Puppeteer will be familiar to people using other browser testing frameworks. You
53+
create an instance of `Browser`, open pages, and then manipulate them with
54+
Puppeteer's API.
4255

43-
**Example** - navigating to https://example.com and saving a screenshot as _example.png_:
56+
**Example** - navigating to https://example.com and saving a screenshot as
57+
_example.png_:
4458

4559
Save file as **example.js**
4660

4761
```js
48-
import puppeteer from "https://deno.land/x/puppeteer@9.0.1/mod.ts";
62+
import puppeteer from "https://deno.land/x/puppeteer@9.0.2/mod.ts";
4963

5064
const browser = await puppeteer.launch();
5165
const page = await browser.newPage();
@@ -61,14 +75,16 @@ Execute script on the command line
6175
deno run -A --unstable example.js
6276
```
6377

64-
Puppeteer sets an initial page size to 800×600px, which defines the screenshot size. The page size can be customized with [`Page.setViewport()`](https://github.com/puppeteer/puppeteer/blob/v5.5.0/docs/api.md#pagesetviewportviewport).
78+
Puppeteer sets an initial page size to 800×600px, which defines the screenshot
79+
size. The page size can be customized with
80+
[`Page.setViewport()`](https://github.com/puppeteer/puppeteer/blob/v5.5.0/docs/api.md#pagesetviewportviewport).
6581

6682
**Example** - create a PDF.
6783

6884
Save file as **hn.js**
6985

7086
```js
71-
import puppeteer from "https://deno.land/x/puppeteer@9.0.1/mod.ts";
87+
import puppeteer from "https://deno.land/x/puppeteer@9.0.2/mod.ts";
7288

7389
const browser = await puppeteer.launch();
7490
const page = await browser.newPage();
@@ -86,14 +102,16 @@ Execute script on the command line
86102
deno run -A --unstable hn.js
87103
```
88104

89-
See [`Page.pdf()`](https://github.com/puppeteer/puppeteer/blob/v5.5.0/docs/api.md#pagepdfoptions) for more information about creating pdfs.
105+
See
106+
[`Page.pdf()`](https://github.com/puppeteer/puppeteer/blob/v5.5.0/docs/api.md#pagepdfoptions)
107+
for more information about creating pdfs.
90108

91109
**Example** - evaluate script in the context of the page
92110

93111
Save file as **get-dimensions.js**
94112

95113
```js
96-
import puppeteer from "https://deno.land/x/puppeteer@9.0.1/mod.ts";
114+
import puppeteer from "https://deno.land/x/puppeteer@9.0.2/mod.ts";
97115

98116
const browser = await puppeteer.launch();
99117
const page = await browser.newPage();
@@ -123,14 +141,17 @@ deno run -A --unstable get-dimensions.js
123141

124142
### How does deno-puppeteer compare to the Node version?
125143

126-
`deno-puppeteer` effectively runs a regular version of Puppeteer, except for some minor changes to make it compatible with Deno.
144+
`deno-puppeteer` effectively runs a regular version of Puppeteer, except for
145+
some minor changes to make it compatible with Deno.
127146

128-
The most noticable difference is likely that instead of some methods taking / returning Node `Buffer`, they take / return `Uint8Array`.
147+
The most noticable difference is likely that instead of some methods taking /
148+
returning Node `Buffer`, they take / return `Uint8Array`.
129149

130150
Other than this, the documentation on https://pptr.dev generally applies.
131151

132152
### How to run in Docker?
133153

134-
An example Dockerfile can be found in this repository. It will install all necessary dependencies, and shows how to run the ./examples/docker.js.
154+
An example Dockerfile can be found in this repository. It will install all
155+
necessary dependencies, and shows how to run the ./examples/docker.js.
135156

136-
It is just meant as a jumping off point - customize it as you wish.
157+
It is just meant as a jumping off point - customize it as you wish.

0 commit comments

Comments
 (0)