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

Issue: Multiple Renders - Different Data #69

Closed
dcflow opened this issue Jan 8, 2019 · 2 comments
Closed

Issue: Multiple Renders - Different Data #69

dcflow opened this issue Jan 8, 2019 · 2 comments

Comments

@dcflow
Copy link

dcflow commented Jan 8, 2019

Hello,

There seems to be an issue with calling the render function multiple times in the same file.

Example: I call the render function on the server twice with the same app but different data:

-server.js-

render(<App data={1}>) 
render(<App data={2}>)

but the render function seem to always pass the data from the first render.

-app.js-

console.log(props.data)
// 1
// 1

I have tried many scenarios but still same results.

Thank You!

@developit
Copy link
Member

@dcflow Definitely going to need more information here - renderToString() is completely synchronous as doesn't do any caching, so it's not really possible for it to bleed across invocations. That means there's something else funky happening in your component tree.

@dcflow
Copy link
Author

dcflow commented Feb 18, 2019

Even I can't give much context since it happens once in a while .. so I will close it and open it if I have more info.

@dcflow dcflow closed this as completed Feb 18, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants