Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
「position:fixedの起点を親要素にするCSS」のHTML
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>縦の動きだけに追従するサイドバー</title>
</head>
<body>
<div id="wrap">
<div id="main">
main-area
</div>
<div id="sidebar">
sidebar
</div>
</div>
</body>
</html>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment