You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Because of that, I need to use an extra useEffect to notify that I'm on the client and then update the state. Notice that typeof window === "undefined" ? "" : window.location.toString() is no-go since you might render the value on page so it is not sustainable.
In my head, this is not a breaking change, but I might be wrong. Also, I would like to work on PR for this if you folks think it is okay to add it to Chakra UI.
The text was updated successfully, but these errors were encountered:
Description
I need to copy a current URL from a browser using a SSR app.
Problem Statement/Justification
The problem is that I cannot use
since the
window
is undefined on the server side.Because of that, I need to use an extra
useEffect
to notify that I'm on the client and then update the state. Notice thattypeof window === "undefined" ? "" : window.location.toString()
is no-go since you might render the value on page so it is not sustainable.Proposed Solution or API
The solution would be to allow imperative usage
Alternatives
No response
Additional Information
In my head, this is not a breaking change, but I might be wrong. Also, I would like to work on PR for this if you folks think it is okay to add it to Chakra UI.
The text was updated successfully, but these errors were encountered: