All Projects → myhere → Vim Nodejs Complete

myhere / Vim Nodejs Complete

nodejs 'omnifunc' function of vim

Labels

Projects that are alternatives of or similar to Vim Nodejs Complete

Vim G
Quick Google lookup directly from Vim
Stars: ✭ 107 (-9.32%)
Mutual labels:  viml
Flatlandia
Vim colorscheme based on flatland with Airline integration.
Stars: ✭ 113 (-4.24%)
Mutual labels:  viml
Vim Jinja
jinja plugins for vim (syntax and indent)
Stars: ✭ 116 (-1.69%)
Mutual labels:  viml
Vim Redl
A better Vim integration story for Clojure
Stars: ✭ 108 (-8.47%)
Mutual labels:  viml
Vim Plug
我的vim插件, 基于vim-plug安装
Stars: ✭ 113 (-4.24%)
Mutual labels:  viml
Ember.vim
Vim plugin for the Emberjs frontend framework
Stars: ✭ 115 (-2.54%)
Mutual labels:  viml
Seti.vim
Stars: ✭ 107 (-9.32%)
Mutual labels:  viml
Greplace.vim
Global search and replace for VI
Stars: ✭ 116 (-1.69%)
Mutual labels:  viml
Vim Swift
Swift filetype plugin for Vim
Stars: ✭ 113 (-4.24%)
Mutual labels:  viml
Incsearch Fuzzy.vim
Stars: ✭ 116 (-1.69%)
Mutual labels:  viml
Vim Pydjango
Ultimate VIM for Python & Django development.
Stars: ✭ 109 (-7.63%)
Mutual labels:  viml
Vim Notes
Easy note taking in Vim
Stars: ✭ 1,518 (+1186.44%)
Mutual labels:  viml
Cscope.vim
A vim plugin to help you to create/update cscope database and connect to existing proper database automatically.
Stars: ✭ 115 (-2.54%)
Mutual labels:  viml
Vim Visualstar
star for Visual-mode.
Stars: ✭ 106 (-10.17%)
Mutual labels:  viml
Keyboard cat.vim
vim plugin for pretending like you can actually type
Stars: ✭ 116 (-1.69%)
Mutual labels:  viml
Vim Colorscheme Switcher
Makes it easy to quickly switch between color schemes in Vim
Stars: ✭ 107 (-9.32%)
Mutual labels:  viml
Vim Multicursor
Allows Vim to use multiple cursors simultaneously
Stars: ✭ 114 (-3.39%)
Mutual labels:  viml
Vim Ruby Xmpfilter
helper for ruby's xmpfilter or seeing_is_believing
Stars: ✭ 117 (-0.85%)
Mutual labels:  viml
Vim Youdao Translater
vim的有道取词翻译插件
Stars: ✭ 116 (-1.69%)
Mutual labels:  viml
Vim Cheat
View cheatsheets via vim
Stars: ✭ 116 (-1.69%)
Mutual labels:  viml

vim-nodejs-complete

Nodejs 'omnifunc' function of vim

Support node's builtin module's method&property completion(ctrl-x ctrl-o) in js file with preview.

Install

Download the tarball and extract to your vimfiles(~/.vim or ~/vimfiles) folder.

Completion require :filetype plugin on, please make sure it's on.

Settings

All the settings is optional.

let g:nodejs_complete_config = {
\  'js_compl_fn': 'jscomplete#CompleteJS',
\  'max_node_compl_len': 15
\}

js_compl_fn

  • String function name, called to complete javascript
  • default to javascriptcomplete#CompleteJS
  • if you want to integrate with jscomplete, set it to jscomplete#CompleteJS, make sure it's installed.

max_node_compl_len

  • Number, length of nodejs complete items. set to 0 if unlimited

Example

var fs = req
// then hit ctrl-x_ctrl-o you'll get:
var fs = require(
// and then hit ctrl-x_ctrl-o again you'll get module name completion

var fs = require('f
// then hit ctrl-x_ctrl-o

fs.
// then hit ctrl-x_ctrl-o

proc
// then hit ctrl-x_ctrl-o

process.ex
// then hit ctrl-x_ctrl-o

Tip

  1. Close the method preview window

    ctrl-w_ctrl-z or :pc.

    If you want close it automatically, put the code(from spf13-vim) below in your .vimrc file.

    " automatically open and close the popup menu / preview window
    au CursorMovedI,InsertLeave * if pumvisible() == 0|silent! pclose|endif
    
  2. About vim's complete

    Vim supports several kinds of completion, :h ins-completion for help.

  3. Completion of module in node_modules will cache result of every js file

    If you modified module in node_modules directory, use code below to clear the cache.

    :unlet b:npm_module_names
    

Feedback

feedback or advice or feature-request

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].