Home AngularJS - Image "onload" event
Reply: 0

AngularJS - Image "onload" event

user481
1#
user481 Published in April 25, 2018, 7:44 pm

I've been searching for an answer to simple but not trivial question: What is a right way to catch image' onload event in Angular only with jqLite? I found this question , but I want some solution with directives.
So as I said, this is not accepted for me:

.controller("MyCtrl", function($scope){
    // ...
    img.onload = function () {
        // ...
    }

because it is in controller, not in directive.

You need to login account before you can post.

About| Privacy statement| Terms of Service| Advertising| Contact us| Help| Sitemap|
Processed in 0.502318 second(s) , Gzip On .

© 2016 Powered by mzan.com design MATCHINFO