React-devtools: Stateless Functional Component source code doesn't show up correctly

Created on 14 Jun 2016  路  5Comments  路  Source: facebook/react-devtools

cc @spicyj

medium good first bug

Most helpful comment

Hey sorry @jaredly I forgot to update the description... 馃槩

The repro is at http://s.codepen.io/spicyj/debug/qNOZOP and the corresponding implementation is at http://codepen.io/spicyj/pen/qNOZOP.

When I right click at a Board component (which is a class component) in devtools and "show source", it jumps to its implementation correctly. However if I click "show source" at Square (which is a stateless functional component), it takes me to the source code of ReactCompositeComponent instead.

Thanks!

All 5 comments

? please elaborate

Hey sorry @jaredly I forgot to update the description... 馃槩

The repro is at http://s.codepen.io/spicyj/debug/qNOZOP and the corresponding implementation is at http://codepen.io/spicyj/pen/qNOZOP.

When I right click at a Board component (which is a class component) in devtools and "show source", it jumps to its implementation correctly. However if I click "show source" at Square (which is a stateless functional component), it takes me to the source code of ReactCompositeComponent instead.

Thanks!

Gotcha! didn't realize what "SFC" meant :)

I'm getting a "This debug view expired." when trying to access the repro link :/

PR https://github.com/facebook/react-devtools/pull/557 try to fixes this issue. @jaredly

Was this page helpful?
0 / 5 - 0 ratings

Related issues

CodyReichert picture CodyReichert  路  5Comments

arghasarkar picture arghasarkar  路  4Comments

zhammer picture zhammer  路  4Comments

mmahalwy picture mmahalwy  路  3Comments

jerikson picture jerikson  路  4Comments