相关疑难解决方法(0)

如何使用JSHint配置Syntastic?

如何使用JSHint的Syntastic Vim插件验证JavaScript代码?

环境:

  • Ubuntu 11.04
  • VIM - Vi IMproved 7.3

我在VIM + JSLint的解决方案之后安装了什么:

  • Vundle
  • 的node.js
  • 节点包管理器
  • jshint,全球
  • 通过Vundle安装的Syntastic(在Vim中使用:BundleInstall命令以确保安装了Syntastic.)

.vimrc中:

set nocompatible               " be iMproved
filetype off                   " required!

set rtp+=~/.vim/bundle/vundle/
call vundle#rc()

" let Vundle manage Vundle
" required! 
Bundle 'gmarik/vundle'

" My Bundles here:
Bundle 'scrooloose/syntastic'

filetype plugin indent on     " required! 

let g:syntastic_enable_signs=1
let g:syntastic_auto_jump=1
let g:syntastic_stl_format = '[%E{Err: %fe #%e}%B{, }%W{Warn: %fw #%w}]'

set statusline+=%#warningmsg#
set statusline+=%{SyntasticStatuslineFlag()}
set statusline+=%*
Run Code Online (Sandbox Code Playgroud)

寻找已安装的可执行文件:

$ which gjslint …
Run Code Online (Sandbox Code Playgroud)

vim jshint syntastic

44
推荐指数
2
解决办法
3万
查看次数

标签 统计

jshint ×1

syntastic ×1

vim ×1