Skip to content
This repository has been archived by the owner on Apr 25, 2021. It is now read-only.

SSR - calculateInitialState #111

Open
kure- opened this issue Sep 4, 2018 · 0 comments
Open

SSR - calculateInitialState #111

kure- opened this issue Sep 4, 2018 · 0 comments

Comments

@kure-
Copy link

kure- commented Sep 4, 2018

Hey,
first of all, really appreaciate your work so far and thanks for your work :)

I'd have a proposal to add a prop to initialState when calculateInitialState is set to false while creating store. E.g. initialized: false. Each recalc. action of redux-responsive would set initialized to true.

It would be a great way to deal with the time e.g. on mobile devices when initial state responds to desktop. In real it renders some components with props composed to desktop and then they swap to mobile, so they look a bit different or even disappear.

Basically it would help people using SSR to not creating custom stores and dispatch actions right after manual dispatching calculateResponsiveState but directly just using selectors to store for that prop :) In fact you just dont want users to see that state of app and you need to display some kind of loader or skeleton :)

Thanks

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

No branches or pull requests

1 participant