Only invoke flow after hyperclick word is clicked
We could use Atom APIs to get word boundary at a range and by default show it as clickable, and after the user clicks it we can invoke Flow to jump for us
Fixes #103
Thoughts @leos @lloiser?
I'm loosely against that. I don't know if flow's word boundaries are the same as Atom's - it also doesn't give you the underlining feedback of whether something is clickable.
Let me look at #103 - I have a few thoughts.
@steelbrain - My initial theory is that https://github.com/steelbrain/flow-ide/blob/master/lib/index.js#L58 won't find a flow.exe file, which triggers a more expensive invocation of flow that goes through node.exe. I need to dust off my windows machine to test that, doing it now.
Confirmed. flow.exe is lightning fast, invoking it via node.exe can take a second. @steelbrain can you reopen #103 and close this? Or create a new issue to track this work if you don't want to continue the reporting issue?
I have found a lot of places where flow fails to go to the definition. Marking these spots as clickable would then lead to issues in our repo again.
I think we have to further investigate the actual slowdown when we call flow. It seems that @leos already found something. I will test it as soon as I can.
Here's the issue that got filed with flow - https://github.com/facebook/flow/issues/4445 - they haven't responded (possibly because it's closed) so maybe open up a new one with the same question?
Pushing the PR that changes search path order should allow folks to workaround the issue by invoking flow.exe explicitly.