Open DoubleOTheven opened 8 years ago
I just discovered that this problem goes away when I remove the jshint plugin for Vim. I am stumped on this one. Any ideas?
I have the same problem with multiple artifacts and just general slow performance in any .js files. I'll remove the jshint plugin and see if there are any improvements.
Even after removing the jshint
plugin, the artifacts still show up for me, but far less often. The artifacts that are showing up appear on any file type, not just .js
files
I went to the https://github.com/wookiehangover/jshint.vim plugin page and noticed they mentioned NodeJS must be installed and in your path. Sure enough, once I setup nodejs, the highlighting and occasional errors went away and I have nice javascript syntax highlighting on my .js files.
I already have nodejs in my path (sym linked through Homebrew package manager). I ended up switching to eslint. Here is how I did it:
~/.vim/bundles/js_hint
let g:syntastic_javascript_checkers = ['eslint']
Installed es_lint via npm:
npm install -g eslint
npm install -g babel-eslint
npm install -g eslint-plugin-react
~/.eslintrc
{
"parser": "babel-eslint",
"env": {
"browser": true,
"node": true
},
"settings": {
"ecmascript": 6,
"jsx": true
},
"plugins": [
"react"
],
"rules": {
"strict": 0,
"quotes": 0,
"no-unused-vars": 0,
"camelcase": 0,
"no-underscore-dangle": 0
}
}
Tada 🎉 . It works...
@Sonblind I think eslint
is preferable to js_hint
(especially since it seems to solve this problem)! Can you create a PR to switch maximum-awesome
to eslint
?
@Sonblind On second thought, after chatting with @rudle, it's probably bad to unconditionally introduce a dependency on node into maximum-awesome.
Problem
After toggling between insert and command mode in Vim (via iTerm, not MacVim. MacVim does not have this problem) for any
*.js
file, I get weird refreshing errors. The keys that I hit in command mode are drawn to the screen. This is only a*.js
file problem. See image below:Those characters are not actually inserted into the file, but only rendered that way. After pushing vim to the background using
ctrl+z
, then bringing it back to the foreground usingfg
on the terminal, vim refreshes the page and those letters are gone.Is there something in my config that is causing the rendering issue, or is this caused by a config in MaximumAwesome?
Vimrc
Vimrc.local