DEV Community

Silviu Bogan
Silviu Bogan

Posted on

How to find the full call stack for a line inside a functional component?

I have a component called Field that is behaving strangely. In some placed Where it is used, it receives, besides other props, the onFocus and onBlur props, but inside it these 2 props are null (the default value set with PropTypes). I put a breakpoint inside its render method and there it seems to receive them as null. So I try to find where that component is used. The Chrome DevTools display just a partial async call stack so I think I will use a component that has a constructor instead of a functional component and put a breakpoint inside the c-tor. I will post here updates if I solve this issue. If you have any ideas on how to solve the issue please let me know here.

Thanks.

Top comments (1)

Collapse
 
silviubogan profile image
Silviu Bogan

I solved the issue in another part of the code, because I did not find a way to see the full stack trace in Chrome DevTools, so I do not know the solution inside the post title.