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

Error in stateless nested component #1008

Closed
Rastopyr opened this issue Feb 5, 2017 · 2 comments
Closed

Error in stateless nested component #1008

Rastopyr opened this issue Feb 5, 2017 · 2 comments

Comments

@Rastopyr
Copy link

Rastopyr commented Feb 5, 2017

version of next.js: 2.0.0-beta.23

i’m reproduced bug:
https://gist.github.com/Rastopyr/7dc995ec888e962aaea387376049c5b2#file-error-md
with this component:
https://gist.github.com/Rastopyr/7dc995ec888e962aaea387376049c5b2#file-component-with-error-js

and problem probably related with this issue
#827

error throw in this line
https://github.com/zeit/next.js/blob/master/client/index.js#L76

NOTE: i can prepare PR, but next.js i use just second day, and not had enough time to research codebase. if somebody can help me, with this issue, i will very grateful

@Rastopyr
Copy link
Author

Rastopyr commented Feb 5, 2017

Also i found, that error fired in initial rendreing on dev/production environment. But in dev env, after HMR reloading, component rendering is ok.

Also i found that doRender fired three times.

  1. Component - is correct (IndexPage for example)
  2. Component - is undefined but component variable the same IndexPage source
  3. Component - ErrorComponent.

@Rastopyr
Copy link
Author

Rastopyr commented Feb 7, 2017

Error was fired from React.js

Info:
https://facebook.github.io/react/docs/error-decoder.html?invariant=32&args[]=33

Close this issue.

@Rastopyr Rastopyr closed this as completed Feb 7, 2017
@lock lock bot locked as resolved and limited conversation to collaborators May 12, 2018
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