This project is AngularJS adaptation of kamlekar's slim-scroll ,
All credits goes to kamlekar. I have just tried to reimplement its work in angularjs.
demo.html
file contains example usage. View demo
$ bower install ng-slim-scroll
- Require
ng-slim-scroll.js
in your html file
<script src="ng-slim-scroll.js"></script>
- Require base CSS style
a. If you use less import ng-slim-scroll.less
in your less file
@import "ng-slim-scroll.less"
b. Else require ng-slim-scroll.css
in your html file
<link rel="stylesheet" href="ng-slim-scroll.css">
- Add module name 'ng-slim-scroll' to your apps dependencies
var app = angular.module('yourApp', ['ngSlimScroll']);
- Add
slim-scroll
ordata-slim-scroll
attribute to the element you want to add slim scroll
<div data-slim-scroll data-options="options"> long long long text </div>
If you want to provide options to slim scroll instance, as defined in original project, you can use options data field.