Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

Angular Prevent Scroll

Directive Prevent Scroll


This directive prevent scrolling the main document when scrolling a target element.

Download https://github.com/gjlacerda/angular-prevent-scroll/archive/master.zip

Demo http://codepen.io/gjlacerda/pen/zKXrYq

Get Started :

  • Add jquery.js, angular.js, prevent-scroll.directive.js to your code:
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/angular.js/1.5.8/angular.min.js"></script>
<script src="js/prevent-scroll.directive.js"></script>
  • Add a prevent-scroll attribute to your element content.
<div prevent-scroll >
Content...
</div>

About

An AngularJS Directive to prevent scroll the document when scrolling a certain element

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages