chore(tooling): configure prettier

This commit is contained in:
peaklabs-dev committed 2026-03-13 23:08:55 +01:00
1 parent 0b9c2836d4
commit 0a4802a314
4 files changed
+48 -7

No files matched your search

+4 -6
View File
@@ -3,16 +3,14 @@ root = true
[*]
charset = utf-8
end_of_line = lf
indent_style = tab
indent_size = 4
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true
[*.md]
trim_trailing_whitespace = false
[*.{yml,yaml}]
indent_size = 2
[compose.yaml]
indent_size = 4
[*.{yml,yaml}]
indent_style = space
indent_size = 2
+16
View File
@@ -0,0 +1,16 @@
.env
.env.*
!.env.testing
!.env.example
!.env.local.example
!.env.production.example
node_modules
vendor
composer.lock
bun.lock
.DS_Store
public/build/**
+27
View File
@@ -0,0 +1,27 @@
import { type Config } from "prettier";
import { type PluginOptions } from "prettier-plugin-tailwindcss";
const config: Config & PluginOptions = {
printWidth: 100, // Matches Rust default and looks the best
useTabs: true, // Preferred for accessibility (screen readers, variable fonts) and tab width is easily adjustable per user
plugins: [
"@ianvs/prettier-plugin-sort-imports",
"prettier-plugin-svelte",
"prettier-plugin-tailwindcss",
],
tailwindStylesheet: "./resources/css/app.css",
overrides: [{ files: "*.svelte", options: { parser: "svelte" } }],
svelteStrictMode: true,
importOrderTypeScriptVersion: "5.0.0",
importOrder: [
"<TYPES>^(node:)",
"<TYPES>",
"<TYPES>^[.]",
"<BUILTIN_MODULES>",
"<THIRD_PARTY_MODULES>",
"^#.+",
"^[.]",
],
};
export default config;
+1 -1
View File
@@ -1,6 +1,6 @@
{
"$schema": "https://www.schemastore.org/tsconfig.json",
"files": ["vite.config.ts", "svelte.config.ts"],
"files": ["vite.config.ts", "svelte.config.ts", "prettier.config.ts"],
"include": ["resources/js/**/*.ts", "resources/js/**/*.svelte"],
"compilerOptions": {