-
Notifications
You must be signed in to change notification settings - Fork 151
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
add 2 snippets: impstd & importstd and import std module url completion #115
Conversation
$0: denotes the final cursor position $1..n: tapstops in sequence impstd => `import {$3} from 'https://deno/std@$1/$2';$0"` importstd => `import (foo|{foo}| * as foo) from 'https://deno/std@$1/$2';$0"`
but need to cache it!
* Cache the result to extension_context.globalState as following format key: [email protected] value: [{name: *, type: ('file'|'dir'), url: *}] * Now, completion item shows differently when import entry is folder or not
@CGQAQ Thanks, this is a cool feature. Since you implemented this a lot in this repository has changed, and also there has been a complete rewrite of the deno.land/x registry powering I think this feature could be extended to support all of
Also I think we should limit our cache to a max of 1 hour, after which we would lazily fetch new versions automatically. |
OK, I'll change it, thank you for your information |
$0: denotes the final cursor position
$1..n: tabstops in sequence
impstd =>
import {$3} from 'https://deno/std@$1/$2';$0"
importstd =>
import (foo|{foo}| * as foo) from 'https://deno/std@$1/$2';$0"
Screenshots:
Implementation of #114