Skip to content

Commit dfe4fdd

Browse files
Fixed FAQs to match style guide
1 parent f2ae74b commit dfe4fdd

File tree

1 file changed

+16
-6
lines changed
  • src/content/docs/browser-rendering

1 file changed

+16
-6
lines changed

src/content/docs/browser-rendering/faq.mdx

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,19 +12,29 @@ import { GlossaryTooltip } from "~/components";
1212

1313
Below you will find answers to our most commonly asked questions. If you cannot find the answer you are looking for, refer to the [Discord](https://discord.cloudflare.com) to explore additional resources.
1414

15-
##### Uncaught (in response) TypeError: Cannot read properties of undefined (reading 'fetch')
15+
### I see `Cannot read properties of undefined (reading 'fetch')` when using Browser Rendering. How do I fix this?
1616

17-
Make sure that you are passing your Browser binding to the `puppeteer.launch` api and that you have [Workers Paid plan](/workers/platform/pricing/).
17+
This error occurs because your Puppeteer launch is not receiving the Browser binding or you are not on a Workers Paid plan. To resolve:
1818

19-
##### Will browser rendering bypass Cloudflare's Bot Protection?
19+
1. Pass your Browser binding into `puppeteer.launch`, for example:
20+
21+
```
22+
import browser from '@cloudflare/workers-browser-rendering';
23+
const browserInstance = await puppeteer.launch({
24+
browserWSEndpoint: browser.endpoint,
25+
// other options
26+
});
27+
```
28+
29+
2. Ensure your account is on a [Workers Paid plan](https://developers.cloudflare.com/workers/platform/pricing/) so that Browser Rendering is enabled.
30+
31+
### Will browser rendering bypass Cloudflare's Bot Protection?
2032

2133
No, Browser Rendering requests are always identified as bots by Cloudflare and do not bypass Bot Protection. Additionally, Browser Rendering respects the robots.txt protocol, ensuring that any disallowed paths specified for user agents are not accessed during rendering.
2234

2335
If you are attempting to scan your **own zone** and need Browser Rendering to access areas protected by Cloudflare’s Bot Protection, you can create a [WAF skip rule](/waf/custom-rules/skip/) to bypass the bot protection using a header or a custom user agent.
2436

25-
## Puppeteer
26-
27-
##### Code generation from strings disallowed for this context while using an Xpath selector
37+
### Why can't I use an XPath selector when using Browser Rendering with Puppeteer?
2838

2939
Currently it's not possible to use Xpath to select elements since this poses a security risk to Workers.
3040

0 commit comments

Comments
 (0)