← Back to CSS domain
CSS.setStyleSheetText
Sets the new stylesheet text.
Domain: CSS
experimental
Parameters
| Name | Type | Description |
styleSheetId | DOM.StyleSheetId | |
text | string | |
Returns
| Name | Type | Description |
sourceMapURL | string | URL of source map associated with script (if any). |
Example Request
{
"id": 1,
"method": "CSS.setStyleSheetText",
"params": {
"styleSheetId": "styleSheetId-value",
"text": "text-value"
}
}
Example Response
{
"id": 1,
"result": {
"sourceMapURL": "sourceMapURL-value"
}
}
Usage in Node.js
const result = await send('CSS.setStyleSheetText', {"styleSheetId": "styleSheetId-value", "text": "text-value"});
console.log(result);
// {"sourceMapURL": "sourceMapURL-value"}