New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for turbolinks #91
Comments
Surprise, surprise! I was just working with Turbolinks and ran into the same issue. This shouldn't be very difficult. |
...I take that back. I thought Turbolinks would have an easy way to opt-out by adding some markup on the target page, but I don't think so. |
For now, when you reach that page, just load |
There we go, semi-fixed. The silly thing here is that when you press 'back', it will loads the page that threw the error, thus triggering the error again... That's the most naive fix I can think of right now. If anyone has a better one (hopefully one that doesn't break the back button), reply here or open a new pull request. |
sigh, I'm hardly surprised turbolinks breaks shit like this On Friday, 18 January 2013 at 6:58 AM, Rico Sta. Cruz wrote:
|
At better_errors loading, once detecting turbolinks, why not pushing into history a (static) page saying « Hey, that's better error again. The previous page thrown an error, we're not sure you want to go back. But if you insist, click here. » This way people wanting to relaunch the page after fixing it can do it, and « n00bs » are not frightened by repetition of the same error. |
I did something else now: Better Errors loads in place (like Turbolinks), but the scripts/styles are now in body, so the page will look fine. It also clears out the scripts and the styles of the host page, so it should look fine. This effectively means that once you reach a page, you can just do a Ctrl+R reload from there (I know that's my instinct). |
Latest version from git now doesn't work at all - just shows standard rails error page.. |
Just tried the edge version with latest turbolinks: |
Actually, when the error page is displayed, head becomes completely empty. When I go back, only title is added, with no stylesheets at all. Tested with turbolinks 0.6.1 and 1.0.0. |
@glebtv, thanks for the report—can you (or anyone else) confirm that it's fixed now? |
I get a standard rails error page. |
Works for me at master (5db3b8e)--tried it with a fresh app and an existing app. If you're getting the standard Rails error page, it may be something specific to your setup. Can you see if I'm guessing better errors isn't loaded at all... say, maybe your env is production, or your Gemfile isn't updated. |
Currently, when turbolinks gem is used, you see this if you come to a page through turbolinks:
The text was updated successfully, but these errors were encountered: