Created
September 24, 2022 14:11
-
-
Save samwx/3fcd3e3d7d19e832b1e9e2c307e6f2aa to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
call plug#begin('~/.vim/plugged') | |
Plug 'mattn/emmet-vim' | |
Plug 'prettier/vim-prettier' | |
Plug 'sheerun/vim-polyglot' | |
Plug 'vim-airline/vim-airline' | |
Plug 'vim-airline/vim-airline-themes' | |
Plug 'dense-analysis/ale' | |
Plug 'preservim/nerdtree' | |
" Themes | |
Plug 'rakr/vim-one' | |
call plug#end() | |
" Configuration | |
syntax on | |
" Use new regular expression engine | |
set re=0 | |
set number | |
filetype plugin indent on | |
set tabstop=4 shiftwidth=2 expandtab | |
set backspace=indent,eol,start | |
let g:airline#extensions#tabline#enabled = 1 | |
" Theme configuration | |
colorscheme one | |
set background=dark | |
let g:one_allow_italics = 1 | |
" ALE config | |
" use ale as a deoplete source | |
let g:ale_completion_enabled = 1 | |
" use eslint, prettier, and stylelint | |
let g:ale_fixers = { | |
\ 'javascript': ['eslint', 'prettier'], | |
\ 'typescript': ['eslint', 'prettier'], | |
\ 'css': ['stylelint', 'prettier'], | |
\ 'html': ['prettier'] | |
\} | |
" use eslint for ts and js | |
let g:ale_linters = { | |
\ 'typescript': [ 'eslint' ], | |
\ 'javascript': [ 'eslint' ] | |
\} | |
" Key Mappings | |
" Tabs | |
map <leader>tn :tabnew<cr> | |
map <leader>t<leader> :tabnext | |
map <leader>tm :tabmove | |
map <leader>tc :tabclose<cr> | |
map <leader>to :tabonly<cr> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment