Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How do I see docs/suggestions for how to use a method? #237

Closed
sethladd opened this issue Dec 16, 2016 · 2 comments
Closed

How do I see docs/suggestions for how to use a method? #237

sethladd opened this issue Dec 16, 2016 · 2 comments

Comments

@sethladd
Copy link

I'm staring at code like this: _counter.abs() and I'm wondering "what goes into abs(), if anything?"

How do I answer that question, using Visual Code? Can I see the API docs? Can it tell me what goes in here?

Or, do I have to jump to the source to see how to use it?

Thanks!

@DanTup
Copy link
Member

DanTup commented Dec 17, 2016

Until #15 is implemented (which needs dart-lang/sdk#27034), the answers are a bit lame. You could either see the args in the completion list before completing, you can hover over the abs part to get a tooltip, or you could F12 into it.

I tend to use the tooltips currently (though I'm not writing much Dart - spare time tends to go on Dart, so still no real Dart work!) but this is one of my big annoyances - it's basically functionality I've not been able to provide yet :(

I've added a comment on dart-lang/sdk#27034 in the hope it might be considered sooner. If not, if I can get a chunk of spare time, I might have another go to see if there's an alternative way I can do it (I'd need to get some sort of AST, maybe the AS exposes something like that through one of the other calls) or see if I can get the SDK building on my machine in a way that I would try implement myself to send a PR (though that's a long shot, I don't know if I know enough to implement it in a way that'd get merged).

@DanTup
Copy link
Member

DanTup commented Feb 12, 2017

I got nowhere trying to make this work using other APIs (and I've spent many hours over several days trying) so I'm gonna mark this as a dupe of #15 and dart-lang/sdk#27034. I don't think there's a good way I can fix this until the Analzyer has support for it (though if anyone has ideas I'm open to suggestions - this is one of my biggest annoyances writing Dart!).

@DanTup DanTup closed this as completed Feb 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants