Closed cristiancs closed 6 years ago
Can you post the code you are using?
The correct behavior is not to interfere with links to different domains.
page('/:first/:second/:page',goBack);
page('/:first/:second',goBack)
function goBack(ctx,next){
if(!actual.called){
actual.called = true;
actual.first = ctx.params.first;
actual.second = ctx.params.second;
}
else{
console.log(ctx);
window.location.href = ctx.path;
}
}
Actually i only do this code to fix another bug (when clicking go back on the browser it doesn't work).
The code works well when you link to example.ru by example, but if it is .com.ru its trigger page.js.
Thanks, this is an interesting one, I'll try to take a look at it soon.
If i have a website example.com and have a link to example.com.co the page.js trigger is executed.