mirror of
https://gitee.com/butubb8/blowfish.git
synced 2025-12-05 14:17:50 +08:00
style: add formatter config
This commit is contained in:
10
.editorconfig
Normal file
10
.editorconfig
Normal file
@@ -0,0 +1,10 @@
|
||||
[*]
|
||||
charset = utf-8
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
trim_trailing_whitespace = true
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[*.md]
|
||||
trim_trailing_whitespace = false
|
||||
40
.prettierignore
Normal file
40
.prettierignore
Normal file
@@ -0,0 +1,40 @@
|
||||
# https://github.com/gohugoio/hugo/blob/b39b24962350090122b5f3927456dde710cffb57/docs/.prettierignore
|
||||
# https://github.com/gohugoio/hugo/blob/b39b24962350090122b5f3927456dde710cffb57/docs/.prettierrc
|
||||
|
||||
# develop
|
||||
.vscode
|
||||
node_modules
|
||||
package.json
|
||||
|
||||
# Hugo
|
||||
assets/lib
|
||||
assets/css/compiled
|
||||
content
|
||||
themes
|
||||
public
|
||||
static
|
||||
*.md
|
||||
|
||||
# Invalid nodes and unexpected tokens, mostly caused by unmatched tags in Hugo statements.
|
||||
# For example:
|
||||
# {{ with .Params.externalUrl }}
|
||||
# <a href="{{ . }}">
|
||||
# {{ else }}
|
||||
# <a href="{{ .RelPermalink }}" class="min-w-full">
|
||||
# {{ end }}
|
||||
#
|
||||
# This create an unclose node
|
||||
|
||||
layouts/_default/_markup/render-heading.html
|
||||
layouts/_default/index.json
|
||||
layouts/_default/list.html
|
||||
layouts/partials/article-link/card-related.html
|
||||
layouts/partials/article-link/card.html
|
||||
layouts/partials/article-link/simple.html
|
||||
layouts/partials/header/basic.html
|
||||
layouts/partials/hero/background.html
|
||||
layouts/partials/head.html
|
||||
layouts/shortcodes/screenshot.html
|
||||
layouts/shortcodes/figure.html
|
||||
|
||||
assets/js/appearance.js
|
||||
45
.prettierrc
Normal file
45
.prettierrc
Normal file
@@ -0,0 +1,45 @@
|
||||
{
|
||||
"singleQuote": false,
|
||||
"tabWidth": 2,
|
||||
"useTabs": false,
|
||||
"semi": true,
|
||||
"trailingComma": "all",
|
||||
"proseWrap": "always",
|
||||
"plugins": [
|
||||
"prettier-plugin-go-template",
|
||||
"@awmottaz/prettier-plugin-void-html"
|
||||
],
|
||||
"overrides": [
|
||||
{
|
||||
"files": ["*.html"],
|
||||
"options": {
|
||||
"useTabs": false,
|
||||
"parser": "go-template",
|
||||
"goTemplateBracketSpacing": true,
|
||||
"printWidth": 112,
|
||||
"bracketSameLine": true
|
||||
}
|
||||
},
|
||||
{
|
||||
"files": ["*.js", "*.mjs", "*.mts", "*.ts"],
|
||||
"options": {
|
||||
"semi": true,
|
||||
"useTabs": false,
|
||||
"printWidth": 112,
|
||||
"singleQuote": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"files": ["*.yml", "*.yaml"],
|
||||
"options": {
|
||||
"singleQuote": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"files": ["*.json*"],
|
||||
"options": {
|
||||
"trailingComma": "none"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -45,7 +45,7 @@ The project includes a Prettier config that helps to format code in line with th
|
||||
|
||||
#### Commit message guidelines
|
||||
|
||||
- Use [Gitmoji](https://gitmoji.dev) in commit messages to provide context.
|
||||
- Use [Gitmoji](https://gitmoji.dev) in PR messages to provide context.
|
||||
- Clearly describe the change with a short summary in the first 72 characters.
|
||||
- Place more detailed explanations in paragraphs below the summary, separated by a blank line.
|
||||
- Use imperative language (ie. "Fix bug", not "Fixed bug" or "Fixes bug").
|
||||
|
||||
14
package-lock.json
generated
14
package-lock.json
generated
@@ -17,6 +17,7 @@
|
||||
"commander": "^14.0.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@awmottaz/prettier-plugin-void-html": "^1.8.0",
|
||||
"@tailwindcss/cli": "^4.1.7",
|
||||
"@tailwindcss/typography": "^0.5.16",
|
||||
"chart.js": "^4.4.9",
|
||||
@@ -77,6 +78,19 @@
|
||||
"url": "https://github.com/sponsors/antfu"
|
||||
}
|
||||
},
|
||||
"node_modules/@awmottaz/prettier-plugin-void-html": {
|
||||
"version": "1.8.0",
|
||||
"resolved": "https://registry.npmjs.org/@awmottaz/prettier-plugin-void-html/-/prettier-plugin-void-html-1.8.0.tgz",
|
||||
"integrity": "sha512-gC1CO6TdjILFBc9UYJHY93RvM76jbNhb8IMiFzNbhyH1aCqvSVVjIhXCEQ9BkLyXGy8gmPfHX3m9BKHnl0edhQ==",
|
||||
"dev": true,
|
||||
"license": "MIT",
|
||||
"engines": {
|
||||
"node": ">=22.0.0"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"prettier": "3.0.0 - 3.5.x"
|
||||
}
|
||||
},
|
||||
"node_modules/@babel/code-frame": {
|
||||
"version": "7.23.5",
|
||||
"resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.23.5.tgz",
|
||||
|
||||
@@ -36,6 +36,7 @@
|
||||
},
|
||||
"homepage": "https://github.com/nunocoracao/blowfish#readme",
|
||||
"devDependencies": {
|
||||
"@awmottaz/prettier-plugin-void-html": "^1.8.0",
|
||||
"@tailwindcss/cli": "^4.1.7",
|
||||
"@tailwindcss/typography": "^0.5.16",
|
||||
"chart.js": "^4.4.9",
|
||||
@@ -123,4 +124,4 @@
|
||||
"@tailwindcss/forms": "^0.5.10",
|
||||
"commander": "^14.0.0"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user