Skip to content
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

Edge case fix for prerender errors #317

Merged
merged 1 commit into from
Aug 19, 2017
Merged

Conversation

developit
Copy link
Member

This adds error and node_modules lookup handling to prerender exception hook. As it turns out, #310 was actually a legit error: @vimeo/player and headroom.js both try to access window.xx on import, so they can't be imported in an SSR context at all. That was all going as planned, but the nice error handler we have for SSR was bailing because it generated an incorrect sourcemap filename. I've added some (possibly non-windows-friendly?) edge case handling to the filename generation, basically implementing rudimentary support for webpack's ~/foo lookup style to point those at node_modules/foo.

Copy link
Member

@reznord reznord left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@developit developit merged commit 1ee0114 into master Aug 19, 2017
@lukeed
Copy link
Member

lukeed commented Aug 19, 2017

Sorry, I looked thru this but forgot to mark Approve /facepalm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants