I found this exception when trying to use react perf tools with components that internally uses ReactDOMServer.renderToStaticMarkup.
Uncaught TypeError: Cannot read property 'parentID' of undefined
at https://unpkg.com/[email protected]/dist/react-dom.js:10986:50
at Array.forEach (native)
at https://unpkg.com/[email protected]/dist/react-dom.js:10980:16
at Array.forEach (native)
at getWasted (https://unpkg.com/[email protected]/dist/react-dom.js:10971:16)
at Object.printWasted (https://unpkg.com/[email protected]/dist/react-dom.js:11142:15)
at eval (eval at transform.run (https://cdnjs.cloudflare.com/ajax/libs/babel-core/5.8.24/browser.js:5811:10), <anonymous>:35:19)
at exec (https://cdnjs.cloudflare.com/ajax/libs/babel-core/5.8.24/browser.js:5866:21)
at runScripts (https://cdnjs.cloudflare.com/ajax/libs/babel-core/5.8.24/browser.js:5903:3)
Minimal reproducible case: https://jsfiddle.net/niwinz/3dw7mt8u/3/
A different but mostly related exception is happens when ?react_perf is used in the url.
You may be asking yourself, why I need to use reactserverdom together with reactdom... I need it to render a svg into a blob and then use that's blob uri as background-url style attribute. I have also other use cases when I need to render to string instead to directly to the dom, so I think that is reasonable usage.
Thanks for reporting. Looks like a bug.
Would you like to investigate why it happens?
@gaearon Just curious, why did you remove good first bug label. Would like to get started on this...
@abdulhannanali the good first bug label just identifies bugs that we think would be easy for first-time contributors. @gaearon may have removed it if he felt the issue was too complex for new contributors, but that doesn't mean you can't work on it! Feel free to look into it and send a PR if you'd like 馃憤 We're also here to answer any questions you have along the way.
Thanks a lot @aweary for the encouragement. I will get started on this right away. The jsFiddle reproduces but I am interested in looking more into it, and if I can reproduce this locally and debug the code. Will keep asking you the questions with time.
The jsfiddle reproduces only one exception, an other happens when ?react_perf parameter is used, maybe is related or maybe not.
In any case, @abdulhannanali thanks for take a look on it!
@gaearon Has there been any progress on this? Is this still waiting to be fixed?
No, as we won鈥檛 be shipping ReactPerf in React 16. The timeline integration is still there (and that鈥檚 the recommended way to debug perf issues), but there won鈥檛 be ReactPerf itself.
Most helpful comment
Thanks a lot @aweary for the encouragement. I will get started on this right away. The jsFiddle reproduces but I am interested in looking more into it, and if I can reproduce this locally and debug the code. Will keep asking you the questions with time.