💻 Software
What's the difference between `syntax` and `filetype` in Vim?
Fresh5 days ago
Mar 15, 20261276 viewsConfidence Score0%
0%
Problem
What's the difference between and in Vim? I learned that I can set syntax and filetype, but I can't understand the difference fully. Is used only for syntax highlighting?
Error Output
syntax
Unverified for your environment
Select your OS to check compatibility.
1 Fix
Canonical Fix
Unverified Fix
New Fix – Awaiting Verification
Fix for: What's the difference between `syntax` and `filetype` in Vim?
Low Risk
affects more things than (for example: syntax highlighting, indenting rules, and other plugins). So generally, you should use unless you only want to change the syntax highlighting. http://vim.wikia.com/wiki/Filetype.vim
Awaiting Verification
Be the first to verify this fix
Sign in to verify this fix