Skip to content
This repository was archived by the owner on Jul 28, 2023. It is now read-only.

Use page.evaluate instead of page.addScriptTag#95

Merged
michalczaplinski merged 1 commit intoperf-and-stress-testingfrom
evaluate-script
Oct 28, 2022
Merged

Use page.evaluate instead of page.addScriptTag#95
michalczaplinski merged 1 commit intoperf-and-stress-testingfrom
evaluate-script

Conversation

@SantosGuillamot
Copy link
Copy Markdown
Contributor

I was testing the workflow with different sites and in some of them (TechCrunch and The Hill for example), there was a Content Security Policy error:

Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'unsafe-eval' 'none'

I think that this can be solved using evaluate instead of addScripTag.

@michalczaplinski
Copy link
Copy Markdown
Collaborator

Great improvement!

@michalczaplinski michalczaplinski merged commit 9d22117 into perf-and-stress-testing Oct 28, 2022
@michalczaplinski michalczaplinski deleted the evaluate-script branch October 28, 2022 20:17
@michalczaplinski michalczaplinski restored the evaluate-script branch October 28, 2022 20:23
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants