Skip to content

Commit 20e43f4

Browse files
authored
chore(web): add prettier config & tailwind class sorting (#955)
1 parent e07e7f3 commit 20e43f4

File tree

6 files changed

+343
-226
lines changed

6 files changed

+343
-226
lines changed

web/.prettierrc.mjs

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
/**
2+
* @see https://prettier.io/docs/en/configuration.html
3+
* @type {import("prettier").Config}
4+
*/
5+
const config = {
6+
trailingComma: "es5",
7+
tabWidth: 4,
8+
printWidth: 105,
9+
singleQuote: true,
10+
plugins: ["prettier-plugin-tailwindcss"],
11+
};
12+
13+
export default config;

web/.vscode/settings.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"prettier.configPath": "./.prettierrc.mjs"
3+
}

web/eslint.config.mjs

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,13 @@
11
// @ts-check
2-
import withNuxt from './.nuxt/eslint.config.mjs'
2+
import withNuxt from "./.nuxt/eslint.config.mjs";
3+
import eslintPrettier from "eslint-config-prettier";
34

45
export default withNuxt(
56
{
67
rules: {
7-
'vue/multi-word-component-names': 'off', // turn off to allow web component parents to work and not trigger errors
8-
'vue/no-v-html': 'off',
8+
"vue/multi-word-component-names": "off", // turn off to allow web component parents to work and not trigger errors
9+
"vue/no-v-html": "off",
910
},
1011
},
11-
)
12+
eslintPrettier
13+
);

web/package-lock.json

Lines changed: 119 additions & 21 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

web/package.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,14 +35,18 @@
3535
"@rollup/plugin-strip": "^3.0.4",
3636
"@tailwindcss/typography": "^0.5.13",
3737
"@types/crypto-js": "^4.2.2",
38+
"@types/eslint-config-prettier": "^6.11.3",
3839
"@types/node": "^18",
3940
"@types/semver": "^7.5.8",
4041
"@vue/apollo-util": "^4.0.0-beta.6",
4142
"@vueuse/core": "^10.11.1",
4243
"@vueuse/nuxt": "^10.9.0",
44+
"eslint-config-prettier": "^9.1.0",
4345
"lodash-es": "^4.17.21",
4446
"nuxt": "^3.11.2",
4547
"nuxt-custom-elements": "2.0.0-beta.18",
48+
"prettier": "3.3.3",
49+
"prettier-plugin-tailwindcss": "^0.6.8",
4650
"shadcn-nuxt": "^0.10.4",
4751
"tailwindcss-animate": "^1.0.7",
4852
"terser": "^5.31.0",

0 commit comments

Comments
 (0)