/sticky

Stick a table header or any other HTML element to the top of the page.

Primary LanguageJavaScriptGNU General Public License v3.0GPL-3.0

Sticky

The simplest way to pin a table header or any other HTML element to the top of the page.

Why Sticky?

Some Reasons To Use:

  • position: fixed is not enough
  • Sticky is dependent free
  • Sticky with tables
  • Weights less than 2KB

Basic Usage

Use "sticky" as id of the element:

    <div id="sticky">Some Content</div>

And then add the sticky.js source on body end:

    <script src="sticky.js"></script>
</body>

Get Now!

Get Sticky to use Today