kakoune: add json and yaml formatter

This commit is contained in:
lelgenio 2025-04-02 17:11:01 -03:00
parent 921413f545
commit 9239cbef77
No known key found for this signature in database
GPG key ID: 2F8F21CE8721456B

View file

@ -15,6 +15,14 @@ hook global WinSetOption filetype=nix %{
set buffer formatcmd 'nixfmt'
}
hook global BufCreate .*\.json %{
set buffer formatcmd 'prettier --parser json'
}
hook global BufCreate .*\.ya?ml %{
set buffer formatcmd 'prettier --parser yaml'
}
hook global BufCreate .*\.html %{
set buffer formatcmd 'prettier --parser html'
}