moved rrweb-snapshot into packages/rrweb-snapshot
This commit is contained in:
20
packages/rrweb-snapshot/test/html/dynamic-stylesheet.html
Normal file
20
packages/rrweb-snapshot/test/html/dynamic-stylesheet.html
Normal file
@@ -0,0 +1,20 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
|
||||
<title>dynamic stylesheet</title>
|
||||
<style></style>
|
||||
<script>
|
||||
const styleEl = document.querySelector('style');
|
||||
const rules = [`body { margin: 0 }`, `p { background: lightpink }`];
|
||||
rules.forEach((rule, idx) => {
|
||||
styleEl.sheet.insertRule(rule, idx);
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<p>p tag</p>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user