[Solved] Fastclick package breaks app

I now also checked the debugger: Although the fastclick.js is included via HTML (and points to the right location, I can download it with the URL), the browser does not seem to load it. If I search in the FF debugger for “fastclick”, I don’t get a result, whereas for other packages the search works. I also can’t find it in the debugger’s source files list.

I hacked into the fastclick.js file in the packages folder and replaced its content by a console.log statement. However, this code won’t be executed, although the same approach works for every other package I tried out. Seems as if FF just refuses to load this particular js file. I can’t see any reason why in the HTML code, though, as Meteor references it just as the others. Very, very strange. I even checked the chmod settings of this file, which are fine.

BTW: The app works fine if it is built with the --production flag. So it seems to be a build problem.

I don’t have fast click in that list also, I do have: https://atmospherejs.com/meteor/mobile-experience in the list. Not sure if every package is listed there (since not all become global).

Here you can see how it’s added to your project:

I am also getting this error. With fastclick in my packages everything is undefined (Meteor, Template, Tracker, etc…) when meteor builds. Any progress on fixing this issue?

Updating to 1.3 added the mobile-experience package… And that includes fast click. I had the standalone fastclick loading before that and the holy nuke of an error got thrown. Removing it and replacing it with mobile-experience should do the trick.

The mobile-experience is also included in 1.2.1. But if I remove fastclick, I cannot find it in the global namespace anymore. It still appears in the versions file, so I am not sure whether it is still active or not.

The mobile-experience package adds fastclick, but it does this only for web.cordova, so it is not available if the app is run on mobile devices via the system web browser:

That’s also why it’s missing in the global namespace in desktop browsers and why the problem seems to be fixed. So that’s not really a solution, unfortunately.

I got the same error. Removing the package made my app work again. Haven’t dug anything yet.

1 Like

At least I am not alone :slight_smile: Maybe you’d like to join the Github issue thread as well?

This might be of help for the actual issue you are trying to solve:

Thanks, but the solutions provided there are either referring to libraries like Fastclick or they’re relying on the latest releases of the mobile device browsers which have disabled the 300ms delay now. As I have to support older devices, this is not a solution for me. So I have to rely on Fastclick finding the best way to eliminate the delay for the device.

As @lucfranken pointed out in the Github issue, this problem was caused by Adblock and has been resolved.

2 Likes