Skip to content

Prevent scroll on the <body /> when component is mounted.

License

Notifications You must be signed in to change notification settings

bhtabor/react-scrolllock

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

React Scroll Lock

Prevent scroll on the <body /> when component is mounted.

Usage

npm install --save react-scrolllock
import ScrollLock from 'react-scrolllock';

class Modal extends Component {
  render () {
    return (
      <div>
        ...
        <ScrollLock />
      </div>
    )
  }
}

About

Prevent scroll on the <body /> when component is mounted.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%