question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Server side rendering is broken after versions 0.15

See original GitHub issue

Hi,

Server side rendering is broken after versions 0.15.

I gives me this error: “Error: Not supported”

I checked the source code:

    if (core_1.JS.browserOrNode().isBrowser && window.location) {
        var url = window.location.href;
        callback({ url: url });
    }
    else {
        throw new Error('Not supported');
    }
});

I guess it’s because that the code is actually checking browser, it there is no “window.location” then it throws “Not supported” error.

However SSR does not have window at all.

Thanks

CJ

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:1
  • Comments:8 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
ajhoolcommented, Apr 9, 2019

I’d be happy to add a PR, I added a related issue: https://github.com/aws-amplify/amplify-js/issues/3015

Even though Amplify does not officially support SSR, would the team be willing to officially support deferring rendering to the client? Something along the lines of “We won’t break SSR, but our components might not render on the server.”

0reactions
github-actions[bot]commented, Jun 12, 2021

This issue has been automatically locked since there hasn’t been any recent activity after it was closed. Please open a new issue for related bugs.

Looking for a help forum? We recommend joining the Amplify Community Discord server *-help channels or Discussions for those types of questions.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to Enable Server-Side Rendering for a React App
In this tutorial, you will initialize a React app using Create React App and then modify the project to enable server-side rendering.
Read more >
Server-side rendering broken after upgrading to MUI 5 (with ...
I migrated my server-side rendering (SSR) working app to version 5 of MUI. I followed the official procedure, but when I disabled JavaScript ......
Read more >
Changelog | Meteor API Docs
Node has been upgraded to version 4.8.4. A new core Meteor package called server-render provides generic support for server-side rendering of HTML, ...
Read more >
Changes — Werkzeug Documentation (2.2.x)
When running the development server in Docker, the debugger security pin is now unique per container. Version 0.15.2¶. Released 2019-04-02. Rule code generation ......
Read more >
AJAX REQUEST NESTED IN THE <HX:DATAITERATOR ... - IBM
PM21875: AJAX REQUEST NESTED IN THE <HX:DATAITERATOR> TAG DOES NOT RENDER PROPERLY ... 7.0.0.15: WebSphere Application Server V7.0 Fix Pack 15 for IBM...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found