Closed overtrue closed 9 years ago
Hi @overtrue,
Unfortunately, we cannot just replace those lines, because Fastclick is a third-party component we use and the code you're showing is their code. Even worse, their repo is not well maintained - I've opened this issue months ago, but I still have no answer.
All in all, unless I find a good replacement for Fastclick with Component support, I think I'm just going to write my own solution to this. For updates on this follow https://github.com/abpetkov/switchery/issues/22.
@abpetkov OK,Thanks.
Hi, @abpetkov
Thank you for creating such a useful tool.
When I use it with RequireJS, reported the following error:
I try to fix it, we found the problem in here: https://github.com/abpetkov/switchery/blob/master/dist/switchery.js#L984
The
require
method will returnmodule.exports
, butmodule.exports
ofFastclick
is not registered.Maybe we need replace following lines:
with:
sorry my poor english, Thanks. :smile: