addStyleTag
Injects a stylesheet into the page, either as a <link> from a URL or as a
<style> element from raw content. When a URL is given the mutation resolves
once the stylesheet has loaded.
**Usage Example:**
mutation InjectStyle {
goto(url: "https://example.com") {
status
}
addStyleTag(content: "body { background: #000; }") {
time
}
}
**Field Definition:**
addStyleTag(
url: String
content: String
): AddStyleTagResponse
Arguments
addStyleTag.url ● String scalar
The URL of the stylesheet to add. One of "url" or "content" is required.
addStyleTag.content ● String scalar
The raw CSS content of the stylesheet to add. One of "url" or "content" is required.
Type
AddStyleTagResponse object
Response returned after injecting a style tag