Fastclick.js integration with AngularJS

前端 未结 2 1350
耶瑟儿~
耶瑟儿~ 2021-02-13 21:14

I\'m building a Cordova application and click response times are slow.

I found the angular-touch plugin for Angular (which, while designed for Angular 1.2.0, looks like

2条回答
  •  梦谈多话
    2021-02-13 21:41

    From this page: the "Angular way" is to .run the FastClick initializer in your Angular JS file. Make sure to load the fastclick.js module before your Angular code.

    HTML:

    
    
    
    
    

    in app.js:

    app.run(function() {
        FastClick.attach(document.body);
    });
    

提交回复
热议问题