1
0
Fork 0
mirror of https://codeberg.org/Mo8it/dotfiles.git synced 2024-10-17 20:52:40 +00:00

Add dprint JS

This commit is contained in:
Mo 2022-12-01 03:52:30 +01:00
parent 74c2f7d598
commit 83b1fcaa57
2 changed files with 10 additions and 7 deletions

View file

@ -1,14 +1,12 @@
{ {
"json": { "includes": ["**/*.{json,md,js}"],
},
"markdown": {
},
"includes": ["**/*.{json,md}"],
"excludes": [ "excludes": [
"**/*-lock.json" "**/*-lock.json",
"**/node_modules"
], ],
"plugins": [ "plugins": [
"https://plugins.dprint.dev/json-0.16.0.wasm", "https://plugins.dprint.dev/json-0.16.0.wasm",
"https://plugins.dprint.dev/markdown-0.14.1.wasm" "https://plugins.dprint.dev/markdown-0.14.2.wasm",
"https://plugins.dprint.dev/typescript-0.78.0.wasm"
] ]
} }

View file

@ -19,6 +19,11 @@ name = "json"
formatter = { command = "dprint", args = ["fmt", "-c", "/home/mo/.config/dprint.json", "--stdin", "json"] } formatter = { command = "dprint", args = ["fmt", "-c", "/home/mo/.config/dprint.json", "--stdin", "json"] }
auto-format = true auto-format = true
[[language]]
name = "javascript"
formatter = { command = "dprint", args = ["fmt", "-c", "/home/mo/.config/dprint.json", "--stdin", "js" ] }
auto-format = true
[[language]] [[language]]
name = "html" name = "html"
formatter = { command = "djlint", args = ["--reformat", "--quiet", "--preserve-blank-lines", "--format-css", "--format-js", "-"] } formatter = { command = "djlint", args = ["--reformat", "--quiet", "--preserve-blank-lines", "--format-css", "--format-js", "-"] }