Prettier 규칙 변경

This commit is contained in:
static
2024-12-25 22:27:43 +09:00
parent 0a2ce3f80a
commit e6f345bd3b
15 changed files with 161 additions and 164 deletions

View File

@@ -1,7 +1,4 @@
{
"useTabs": true,
"singleQuote": true,
"trailingComma": "none",
"printWidth": 100,
"plugins": ["prettier-plugin-svelte", "prettier-plugin-tailwindcss"],
"overrides": [

View File

@@ -1,14 +1,14 @@
import { defineConfig } from 'drizzle-kit';
if (!process.env.DATABASE_URL) throw new Error('DATABASE_URL is not set');
import { defineConfig } from "drizzle-kit";
if (!process.env.DATABASE_URL) throw new Error("DATABASE_URL is not set");
export default defineConfig({
schema: './src/lib/server/db/schema.ts',
schema: "./src/lib/server/db/schema.ts",
dbCredentials: {
url: process.env.DATABASE_URL
url: process.env.DATABASE_URL,
},
verbose: true,
strict: true,
dialect: 'sqlite'
dialect: "sqlite",
});

View File

@@ -1,34 +1,34 @@
import prettier from 'eslint-config-prettier';
import js from '@eslint/js';
import { includeIgnoreFile } from '@eslint/compat';
import svelte from 'eslint-plugin-svelte';
import globals from 'globals';
import { fileURLToPath } from 'node:url';
import ts from 'typescript-eslint';
const gitignorePath = fileURLToPath(new URL('./.gitignore', import.meta.url));
import prettier from "eslint-config-prettier";
import js from "@eslint/js";
import { includeIgnoreFile } from "@eslint/compat";
import svelte from "eslint-plugin-svelte";
import globals from "globals";
import { fileURLToPath } from "node:url";
import ts from "typescript-eslint";
const gitignorePath = fileURLToPath(new URL("./.gitignore", import.meta.url));
export default ts.config(
includeIgnoreFile(gitignorePath),
js.configs.recommended,
...ts.configs.recommended,
...svelte.configs['flat/recommended'],
...svelte.configs["flat/recommended"],
prettier,
...svelte.configs['flat/prettier'],
...svelte.configs["flat/prettier"],
{
languageOptions: {
globals: {
...globals.browser,
...globals.node
}
}
...globals.node,
},
},
},
{
files: ['**/*.svelte'],
files: ["**/*.svelte"],
languageOptions: {
parserOptions: {
parser: ts.parser
}
}
}
parser: ts.parser,
},
},
},
);

View File

@@ -1,6 +1,6 @@
export default {
plugins: {
tailwindcss: {},
autoprefixer: {}
}
autoprefixer: {},
},
};

View File

@@ -1,3 +1,3 @@
@import 'tailwindcss/base';
@import 'tailwindcss/components';
@import 'tailwindcss/utilities';
@import "tailwindcss/base";
@import "tailwindcss/components";
@import "tailwindcss/utilities";

View File

@@ -1,6 +1,6 @@
import { drizzle } from 'drizzle-orm/better-sqlite3';
import Database from 'better-sqlite3';
import { env } from '$env/dynamic/private';
if (!env.DATABASE_URL) throw new Error('DATABASE_URL is not set');
import { drizzle } from "drizzle-orm/better-sqlite3";
import Database from "better-sqlite3";
import { env } from "$env/dynamic/private";
if (!env.DATABASE_URL) throw new Error("DATABASE_URL is not set");
const client = new Database(env.DATABASE_URL);
export const db = drizzle(client);

View File

@@ -1,6 +1,6 @@
import { sqliteTable, text, integer } from 'drizzle-orm/sqlite-core';
import { sqliteTable, text, integer } from "drizzle-orm/sqlite-core";
export const user = sqliteTable('user', {
id: integer('id').primaryKey(),
age: integer('age')
export const user = sqliteTable("user", {
id: integer("id").primaryKey(),
age: integer("age"),
});

View File

@@ -1,5 +1,5 @@
<script lang="ts">
import '../app.css';
import "../app.css";
let { children } = $props();
</script>

View File

@@ -1,5 +1,5 @@
import adapter from '@sveltejs/adapter-node';
import { vitePreprocess } from '@sveltejs/vite-plugin-svelte';
import adapter from "@sveltejs/adapter-node";
import { vitePreprocess } from "@sveltejs/vite-plugin-svelte";
/** @type {import('@sveltejs/kit').Config} */
const config = {
@@ -11,8 +11,8 @@ const config = {
// adapter-auto only supports some environments, see https://svelte.dev/docs/kit/adapter-auto for a list.
// If your environment is not supported, or you settled on a specific environment, switch out the adapter.
// See https://svelte.dev/docs/kit/adapters for more information about adapters.
adapter: adapter()
}
adapter: adapter(),
},
};
export default config;

View File

@@ -1,11 +1,11 @@
import type { Config } from 'tailwindcss';
import type { Config } from "tailwindcss";
export default {
content: ['./src/**/*.{html,js,svelte,ts}'],
content: ["./src/**/*.{html,js,svelte,ts}"],
theme: {
extend: {}
extend: {},
},
plugins: []
plugins: [],
} satisfies Config;

View File

@@ -1,6 +1,6 @@
import { sveltekit } from '@sveltejs/kit/vite';
import { defineConfig } from 'vite';
import { sveltekit } from "@sveltejs/kit/vite";
import { defineConfig } from "vite";
export default defineConfig({
plugins: [sveltekit()]
plugins: [sveltekit()],
});