
Playwright Scraper
Pricing
Pay per usage

Playwright Scraper
Crawls websites with the headless Chromium, Chrome, or Firefox browser and Playwright library using a provided server-side Node.js code. Supports both recursive crawling and a list of URLs. Supports login to a website.
4.3 (7)
Pricing
Pay per usage
31
Monthly users
142
Runs succeeded
98%
Response time
3.1 days
Last modified
10 months ago
the json tells me one thing the log gives me an error when i swap it to correct the json error
i code json with preNavigationHooks as an array and the json checker flags it saying it must be a string. I correct it make it a damn string and the run fails whats the error you ask???? oh crap it says preNavigationHooks should be an array. Like no shit it should be an array! fix your shit man.
immovable_investigator
Field "preNavigationHooks" should be string
immovable_investigator
2024-08-22T20:17:55.130Z ERROR Input parameter "preNavigationHooks" is not an array!
Hello and thank you for your interest in this Actor!
I apologize for the frustration this issue has caused.
The preNavigationHooks
field in the Web Scraper actor expects a string in the JSON configuration. This string should contain the JavaScript code that specifies an array of functions. For example:
"preNavigationHooks": "[ async (crawlingContext) => { console.log('first pre hook', crawlingContext.request.url); }, async (crawlingContext) => { console.log('pre hook2', crawlingContext.request.url); }]"
At runtime, this string is evaluated to create the required array of functions. If the format is not correct, you may see errors like the ones you mentioned. Please ensure the input follows the format above to avoid these issues.
We’re working to make these requirements more consistent and user-friendly. For example, you can use the code editor on the Input tab in the Apify Console to set this up (and then just copy the JSON input to your script). The code editor provides a better user experience with code highlighting and automatic JavaScript syntax checking.
I’m closing this issue now, but feel free to reach out if you need further assistance. Thank you for your patience and understanding!
Pricing
Pricing model
Pay per usageThis Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage.