moroshko / react-scanner

Extract React components and props usage from code.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Feature Request: Make parsing failures more verbose

lmosele opened this issue · comments

console.error(`Failed to parse: ${filePath}`);

I'm currently operating within a React/Flow codebase and am finding that everything is awesome aside from a miscelleanous series of components fail to be parsed entirely. It's not clear as to why since the error itself isnt surfaced, but I suspect it either trips up on the flow types of any extra exports within the file?

If possible I'd love to see a few more config options that specify pre-parsing rules (ie maybe a regex exclude?). Not entirely sure what the best move would be, but open to helping out if necessary!

Flow is not supported at the moment (we only have TypeScript support).
PR is welcome!