diff --git a/web/.prettierignore b/web/.prettierignore new file mode 100644 index 000000000..247be9376 --- /dev/null +++ b/web/.prettierignore @@ -0,0 +1,4 @@ +*.md +static +.docusaurus + diff --git a/web/.prettierrc b/web/.prettierrc new file mode 100644 index 000000000..205890f98 --- /dev/null +++ b/web/.prettierrc @@ -0,0 +1,8 @@ +{ + "plugins": ["prettier-plugin-tailwindcss"], + "trailingComma": "es5", + "semi": false, + "singleQuote": true, + "endOfLine": "lf", + "tabWidth": 2 +} diff --git a/web/package-lock.json b/web/package-lock.json index 4164b5d1a..fefe99eb2 100644 --- a/web/package-lock.json +++ b/web/package-lock.json @@ -32,6 +32,8 @@ }, "devDependencies": { "@docusaurus/module-type-aliases": "2.2.0", + "prettier": "^3.0.3", + "prettier-plugin-tailwindcss": "^0.5.6", "remark-cli": "^11.0.0", "remark-validate-links": "^12.1.1" }, @@ -9990,6 +9992,93 @@ "node": ">=4" } }, + "node_modules/prettier": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.0.3.tgz", + "integrity": "sha512-L/4pUDMxcNa8R/EthV08Zt42WBO4h1rarVtK0K+QJG0X187OLo7l699jWw0GKuwzkPQ//jMFA/8Xm6Fh3J/DAg==", + "dev": true, + "bin": { + "prettier": "bin/prettier.cjs" + }, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/prettier/prettier?sponsor=1" + } + }, + "node_modules/prettier-plugin-tailwindcss": { + "version": "0.5.6", + "resolved": "https://registry.npmjs.org/prettier-plugin-tailwindcss/-/prettier-plugin-tailwindcss-0.5.6.tgz", + "integrity": "sha512-2Xgb+GQlkPAUCFi3sV+NOYcSI5XgduvDBL2Zt/hwJudeKXkyvRS65c38SB0yb9UB40+1rL83I6m0RtlOQ8eHdg==", + "dev": true, + "engines": { + "node": ">=14.21.3" + }, + "peerDependencies": { + "@ianvs/prettier-plugin-sort-imports": "*", + "@prettier/plugin-pug": "*", + "@shopify/prettier-plugin-liquid": "*", + "@shufo/prettier-plugin-blade": "*", + "@trivago/prettier-plugin-sort-imports": "*", + "prettier": "^3.0", + "prettier-plugin-astro": "*", + "prettier-plugin-css-order": "*", + "prettier-plugin-import-sort": "*", + "prettier-plugin-jsdoc": "*", + "prettier-plugin-organize-attributes": "*", + "prettier-plugin-organize-imports": "*", + "prettier-plugin-style-order": "*", + "prettier-plugin-svelte": "*" + }, + "peerDependenciesMeta": { + "@ianvs/prettier-plugin-sort-imports": { + "optional": true + }, + "@prettier/plugin-pug": { + "optional": true + }, + "@shopify/prettier-plugin-liquid": { + "optional": true + }, + "@shufo/prettier-plugin-blade": { + "optional": true + }, + "@trivago/prettier-plugin-sort-imports": { + "optional": true + }, + "prettier-plugin-astro": { + "optional": true + }, + "prettier-plugin-css-order": { + "optional": true + }, + "prettier-plugin-import-sort": { + "optional": true + }, + "prettier-plugin-jsdoc": { + "optional": true + }, + "prettier-plugin-marko": { + "optional": true + }, + "prettier-plugin-organize-attributes": { + "optional": true + }, + "prettier-plugin-organize-imports": { + "optional": true + }, + "prettier-plugin-style-order": { + "optional": true + }, + "prettier-plugin-svelte": { + "optional": true + }, + "prettier-plugin-twig-melody": { + "optional": true + } + } + }, "node_modules/pretty-error": { "version": "4.0.0", "license": "MIT", @@ -20527,6 +20616,19 @@ "prepend-http": { "version": "2.0.0" }, + "prettier": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.0.3.tgz", + "integrity": "sha512-L/4pUDMxcNa8R/EthV08Zt42WBO4h1rarVtK0K+QJG0X187OLo7l699jWw0GKuwzkPQ//jMFA/8Xm6Fh3J/DAg==", + "dev": true + }, + "prettier-plugin-tailwindcss": { + "version": "0.5.6", + "resolved": "https://registry.npmjs.org/prettier-plugin-tailwindcss/-/prettier-plugin-tailwindcss-0.5.6.tgz", + "integrity": "sha512-2Xgb+GQlkPAUCFi3sV+NOYcSI5XgduvDBL2Zt/hwJudeKXkyvRS65c38SB0yb9UB40+1rL83I6m0RtlOQ8eHdg==", + "dev": true, + "requires": {} + }, "pretty-error": { "version": "4.0.0", "requires": { diff --git a/web/package.json b/web/package.json index 3b6d2c7f6..a4068e473 100644 --- a/web/package.json +++ b/web/package.json @@ -41,6 +41,8 @@ }, "devDependencies": { "@docusaurus/module-type-aliases": "2.2.0", + "prettier": "^3.0.3", + "prettier-plugin-tailwindcss": "^0.5.6", "remark-cli": "^11.0.0", "remark-validate-links": "^12.1.1" }, diff --git a/web/prettier.config.js b/web/prettier.config.js deleted file mode 100644 index bab4b2ea0..000000000 --- a/web/prettier.config.js +++ /dev/null @@ -1,6 +0,0 @@ -// Used to format the code in the docs -module.exports = { - trailingComma: 'es5', - semi: false, - singleQuote: true, -} \ No newline at end of file