Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- app.directive('scroll', function($location){
- return{
- restrict: 'A',
- link: function(scope, element, attrs){
- element.on('scroll', function(){
- let fh = $('#ngview').height();
- let nh = Math.round($(element).height() + $(element).scrollTop());
- if(fh == nh){
- //Here we do what we need
- }
- })
- }
- }
- });
- <div class="col-md-12 middle-body" scroll>
- <div ng-show="showUserModal" ng-include="'partial/loginModal.html'"></div>
- <div class="user-loader" ng-show="loading">
- <div class="spinner"></div>
- </div>
- <div ng-view id="ngview">
- </div>
- </div>
- var app = angular.module('app',
- [
- 'ngRoute',
- 'lastUpdateModule',
- 'selectedByGenreModule',
- 'currentFilmModule',
- 'httpFactory',
- 'userModule',
- 'accountModule'
- ]);
- const SelectedByGenreModule = require('../controllers/selectedByGenre.controller.js')
Add Comment
Please, Sign In to add comment