aboutsummaryrefslogtreecommitdiff
path: root/after
diff options
context:
space:
mode:
authorjdhao <jdhao@hotmail.com>2022-08-06 14:20:28 +0800
committerjdhao <jdhao@hotmail.com>2022-08-06 14:20:28 +0800
commited5ddf60ccaaeaf3ff526ba8267b489f21b94a5d (patch)
tree59d0f6a347cbc9e23e8652aa1c41691650cda347 /after
parentbcdc8d3f663f85b2f1c0071200d9a972455ad74d (diff)
add setup for javascript
Diffstat (limited to 'after')
-rw-r--r--after/ftplugin/javascript.vim8
1 files changed, 8 insertions, 0 deletions
diff --git a/after/ftplugin/javascript.vim b/after/ftplugin/javascript.vim
new file mode 100644
index 0000000..c629428
--- /dev/null
+++ b/after/ftplugin/javascript.vim
@@ -0,0 +1,8 @@
+" Disable inserting comment leader after hitting o or O or <Enter>
+set formatoptions-=o
+set formatoptions-=r
+
+set tabstop=2 " number of visual spaces per TAB
+set softtabstop=2 " number of spaces in tab when editing
+set shiftwidth=2 " number of spaces to use for autoindent
+set expandtab " expand tab to spaces so that tabs are spaces