Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

angular-lazy-img not working on safari browser #49

Open
shravan-saini opened this issue Apr 30, 2019 · 0 comments
Open

angular-lazy-img not working on safari browser #49

shravan-saini opened this issue Apr 30, 2019 · 0 comments

Comments

@shravan-saini
Copy link

shravan-saini commented Apr 30, 2019

I am using angular-lazy-img with angular 1.5.8. The image lazy load is working fine on chrome but not working safari.

here is the sample img tag---
< img id="list-img-id" class="list-imgs lazy list-row-img" lazy-img="{{near.coverImage}}" alt="{{near.displayName + ' ' +near.displayNameLocation}}" style="" >

here is lazyImgConfig function---

config(['lazyImgConfigProvider', function(lazyImgConfigProvider) {
setTimeout(function() {
console.log('lazyImgConfigProvider',lazyImgConfigProvider);
var scrollable = document.querySelector('#hawai');
lazyImgConfigProvider.setOptions({
offset: 1, // how early you want to load image (default = 100)
errorClass: 'error', // in case of loading image failure what class should be added (default = null)
successClass: 'success', // in case of loading image success what class should be added (default =
null)
onError: function(image) {}, // function fired on loading error
onSuccess: function(image) {}, // function fired on loading success
container: angular.element(scrollable) // if scrollable container is not $window then provide it here
});
}, 1000)

}]);

please let me know whats the issue and how can i fix it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant