Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Go to Latest
method Page.prototype.addScriptTag
import { Page } from "https://deno.land/x/puppeteer@14.1.1/vendor/puppeteer-core/puppeteer/common/Page.js";

Adds a <script> tag into the page with the desired URL or content.

Parameters

options: { url?: string; path?: string; content?: string; type?: string; id?: string; }

Returns

Promise<ElementHandle>

Promise which resolves to the added tag when the script's onload fires or when the script content was injected into frame.