install.fairie/dotfiles/.vim/plugged/vim-prettier/autoload/prettier/logging/error.vim
Git E2E Dev Test Username a8e788a215 git subrepo clone (merge) https://github.com/prettier/vim-prettier.git ./dotfiles/.vim/plugged/vim-prettier
subrepo:
  subdir:   "dotfiles/.vim/plugged/vim-prettier"
  merged:   "5e6cca21"
upstream:
  origin:   "https://github.com/prettier/vim-prettier.git"
  branch:   "master"
  commit:   "5e6cca21"
git-subrepo:
  version:  "0.4.3"
  origin:   "???"
  commit:   "???"
2022-10-18 10:36:42 -04:00

12 lines
482 B
VimL

let s:PREFIX_MSG = 'Prettier: '
let s:ERRORS = {
\ 'EXECUTABLE_NOT_FOUND_ERROR': 'no prettier executable installation found',
\ 'PARSING_ERROR': 'failed to parse buffer',
\ }
let s:DEFAULT_ERROR = get(s:, 'PARSING_ERROR')
function! prettier#logging#error#log(...) abort
let l:error = a:0 > 0 ? a:1 : s:DEFAULT_ERROR
let l:msg = a:0 > 1 ? ': ' . a:2 : ''
echohl WarningMsg | echom s:PREFIX_MSG . get(s:ERRORS, l:error, s:DEFAULT_ERROR) . l:msg | echohl NONE
endfunction