vim-node
vim-node copied to clipboard
gf on require() of core modules
Hi,
New to vim-node so forgive me if I'm misusing or have misconfigured something.
I'm hitting 'gf' on a require("fs") statement. It's navigating to the core fs module but does two things I'm not expecting:
- Fetching the file over curl a-new each time (even if I've just navigated to it a few moments ago). I'm sometimes offline, so some reasonable caching defaults (or local-db fallback option) would be good -- not to mention, internet speeds are fast but non-zero.
- The opened module is replacing the existing buffer -- my natural instinct of hitting ':q' to return closes everything out. I could use ':e#' but I think we should be going back to the previous buffer by default on ':q'?
Thanks, Phil
Hey!
Thanks for giving Node.vim a try!
I'll get back to you on point 1, but point 2 is a common Vim issue. I actually have a plugin for that: https://github.com/moll/vim-bbye. :-)
You can also open the module in a split with <C-w>f (<C-w>gf for a tab split).
Ah, great.