Source code

Revision control

Copy as Markdown

Other Tools

<!DOCTYPE html>
<html>
<title>View transitions: use snapshot containing block for static position in iframe (ref)</title>
<style>
#inner {
width: 400px;
height: 200px;
}
</style>
<iframe id="inner" srcdoc="
<style>
body {
height: 200vh;
background: limegreen;
overflow: hidden;
}
</style>
<body></body>
"></iframe>
<script>
onload = () => {
inner.contentWindow.scrollTo(0, 100);
};
</script>