Closed npearson72 closed 5 years ago
Sorry I didn't troubleshoot properly. It seems related to https://github.com/posva/vim-vue.
This provides auto complete functionality in a *.vue file, and when used with coc-vetur it throws an error.
It should not related to posva/vim-vue, try paste all error messages from :messages
if you still have problem after update.
Here are the messages I get:
match 1 of 5
match 1 of 5
match 1 of 5
[coc.nvim] Emmet Abbreviation
[coc.nvim] Emmet Abbreviation
match 1 of 10
match 1 of 10
match 1 of 10
match 1 of 10
match 1 of 2
match 1 of 2
[coc.nvim] vetur complete error: TypeError: Cannot read property 'hasOwnProperty
' of null
[coc.nvim] vetur complete error: TypeError: Cannot read property 'hasOwnProperty
' of null
I've attached a screenshot:
My Neovim info:
NVIM v0.3.2
Build type: Release
LuaJIT 2.0.5
Compilation: /usr/local/Homebrew/Library/Homebrew/shims/mac/super/clang -Wconversion -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1 -DNDEBUG -DMIN_LOG_LEVEL=3 -Wall -Wextra -pedantic -Wno-unused-parameter -Wstrict-prototypes -std=gnu99 -Wimplicit-fallthrough -Wvla -fstack-protector-strong -fdiagnostics-color=auto -DINCLUDE_GENERATED_DECLARATIONS -D_GNU_SOURCE -DNVIM_MSGPACK_HAS_FLOAT32 -DNVIM_UNIBI_HAS_VAR_FROM -I/tmp/neovim-20181231-68781-192nq64/neovim-0.3.2/build/config -I/tmp/neovim-20181231-68781-192nq64/neovim-0.3.2/src -I/usr/local/include -I/usr/local/opt/gettext/include -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include -I/tmp/neovim-20181231-68781-192nq64/neovim-0.3.2/build/src/nvim/auto -I/tmp/neovim-20181231-68781-192nq64/neovim-0.3.2/build/include
Compiled by brew@Mojave.local
Features: +acl +iconv +jemalloc +tui
See ":help feature-compile"
system vimrc file: "$VIM/sysinit.vim"
fall-back for $VIM: "/usr/local/Cellar/neovim/0.3.2/share/nvim"
Run :checkhealth for more info
Here is my plugins vimrc:
call plug#begin("$HOME/.config/nvim/plugged")
" UI/UX
Plug 'bling/vim-airline'
Plug 'reedes/vim-colors-pencil'
Plug 'gcmt/taboo.vim'
Plug 'vim-scripts/restore_view.vim'
Plug 'ryanoasis/vim-devicons'
" Syntax highlighting
Plug 'w0rp/ale'
Plug 'sheerun/vim-polyglot'
Plug 'tiagofumo/vim-nerdtree-syntax-highlight'
Plug 'prettier/vim-prettier', { 'do': 'yarn install' }
" File management, search, navigation
Plug 'mileszs/ack.vim'
Plug '/usr/local/opt/fzf' " Homebrew managed fzf binary
Plug 'junegunn/fzf.vim'
Plug 'skwp/greplace.vim'
Plug 'scrooloose/nerdtree'
Plug 'vim-scripts/zoomwintab.vim'
" Snippets
Plug 'SirVer/ultisnips'
Plug 'npearson72/vim-personal-snippets'
" Autocompletion
Plug 'neoclide/coc.nvim', { 'do': 'yarn install' }
" Formatters, selectors, accelerators
Plug 'tpope/vim-commentary'
Plug 'tpope/vim-endwise'
Plug 'tpope/vim-projectionist'
Plug 'tpope/vim-surround'
Plug 'suy/vim-context-commentstring' " For JSX comments
Plug 'terryma/vim-multiple-cursors'
Plug 'godlygeek/tabular'
Plug 'junegunn/vim-peekaboo'
Plug 'simnalamburt/vim-mundo'
Plug 'othree/eregex.vim'
" Ruby/Rails
Plug 'vim-ruby/vim-ruby'
Plug 'henrik/vim-ruby-runner'
Plug 'nelstrom/vim-textobj-rubyblock'
Plug 'kana/vim-textobj-user' " Required for vim-textobj-rubyblock
" Git
Plug 'tpope/vim-fugitive'
Plug 'mhinz/vim-signify'
call plug#end()
" Ack
let g:ackhighlight=1
if executable('rg')
let g:ackprg='rg --sort=path --line-number --smart-case'
endif
" Airline
let g:airline#extensions#whitespace#enabled=0
if !exists('g:airline_symbols')
let g:airline_symbols={}
endif
" Ale
let g:ale_lint_on_text_changed='never'
let g:ale_lint_on_enter=0
" FZF
let g:fzf_layout={ 'down': '40%' }
" Gsearch
let g:grep_cmd_opts='--line-numbers --noheading'
" NERDTree
let NERDTreeBookmarksFile=expand("$HOME/.local/shared/nvim/NERDTreeBookmarks")
let NERDTreeShowHidden=1
let NERDTreeQuitOnOpen=1
" Prettier
let g:prettier#config#print_width=100
let g:prettier#quickfix_enabled=0
autocmd BufWritePre *.js,*.jsx,*.mjs,*.ts,*.tsx,*.css,*.less,*.scss,*.json,*.graphql,*.vue,*.yaml,*.html PrettierAsync
" Projectionist
autocmd User ProjectionistDetect
\ call projectionist#append(getcwd(),
\ {
\ 'app/*.rb': {
\ 'alternate': 'spec/{}_spec.rb'
\ },
\ 'spec/*_spec.rb': {
\ 'alternate': 'app/{}.rb'
\ },
\ })
" RubyRunner
let g:RubyRunner_key='<leader>e'
let g:RubyRunner_open_below=1
let g:RubyRunner_window_size=10
" Taboo
let g:taboo_tab_format=' %f '
" UltiSnips
let g:UltiSnipsEditSplit='vertical'
let g:UltiSnipsExpandTrigger="<c-y>"
let g:UltiSnipsSnippetDirectories=[
\ $HOME."/.config/nvim/plugged/vim-personal-snippets/UltiSnips",
\]
" Vim polyglot
" Fix for Vue slowness related to posva/vim-vue (part of sheerun/vim-polyglot)
let g:vue_disable_pre_processors=1
Have you tried :CocUpdate
to update to latest coc-vetur?
Just updated and that fixed it! Thanks man!!
I get this error when working with template markup:
[coc.nvim] vetur complete error: TypeError: Cannot read property 'hasOwnProperty' of null
To reproduce, use with coc-html. Create an html element within the
<template>
and start typing the inner text.Example: