Skip to content

vovayatsyuk/shrink-to-viewport

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Shrink to Viewport

The script calculates maximum of available height for the element to fit the viewport and set it as max-height style.

Usage

new ShrinkToViewport(document.getElementById('aside'), {
    offset: 20
});

About

Automatically update element's max-height to fit viewport size https://vovayatsyuk.github.io/shrink-to-viewport/

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published