Skip to content

danbrianwhite/scrollparent.js

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

scrollparent.js

A function to get the scrolling parent of an html element.

Install

npm install scrollparent --save

Example

var Scrollparent = require("scrollparent");

Scrollparent(document.getElementById("content")) // document.body
var Scrollparent = require("scrollparent");

Scrollparent(document.getElementById("inside-a-scrolling-div")) // HTMLDivElement

Contributors

  • Ola Holmström (@olahol)
  • Bart Nagel (@tremby)

License

MIT

About

A function to get the scrolling parent of an html element.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • HTML 82.6%
  • JavaScript 17.4%