Open tegola opened 9 years ago
After playing a bit with the js file generated by CoffeeScript (which I'm not familiar with), I've managed to fix it:
Here's the original bit:
if (typeof toPage === "string") {
nextPage = $(toPage);
if (!nextPage.length) {
showPageByHref(toPage, {
animation: animation
});
return;
} else {
toPage = nextPage;
}
}
And here's the fix:
if (typeof toPage === "string") {
try {
nextPage = $(toPage);
}
catch(e){
// toPage was not a valid selector
showPageByHref(toPage, {
animation: animation
});
return;
}
toPage = nextPage;
}
I'm not sure if it's the right fix, but it works for me. Summoning @thomasyip and @davidkaneda to have a look at it and update the original CoffeeScript file.
Thanks @tegola for this fix. I used it for an old jQTouch version.
I'm glad it helped 👍
Hello, I'm hoping this project has still a little support from the community. I've switched from a pre-coffeescript version of jqtouch to the latest one, and I am having troubles porting my app.
The main issue is that the
goTo
method, that once supported both IDs and urls, now gives an error.With Zepto:
With jQuery 2 + jqtouch-jquery2.js:
Any cue?
Thanks