From e792692a61239108b6d8189692147ea6344f7164 Mon Sep 17 00:00:00 2001 From: Nulo Date: Sat, 23 Dec 2023 15:59:09 -0300 Subject: [PATCH] sitio: prettier razonable --- sitio/.prettierrc | 4 --- sitio/package.json | 60 ++++++++++++++++----------------- sitio/postcss.config.cjs | 16 ++++----- sitio/src/app.d.ts | 14 ++++---- sitio/src/app.html | 18 +++++----- sitio/src/routes/+layout.svelte | 2 +- sitio/src/routes/+page.svelte | 4 ++- sitio/svelte.config.js | 22 ++++++------ sitio/tailwind.config.cjs | 10 +++--- sitio/tsconfig.json | 32 +++++++++--------- sitio/vite.config.ts | 6 ++-- 11 files changed, 93 insertions(+), 95 deletions(-) diff --git a/sitio/.prettierrc b/sitio/.prettierrc index 7ebb855..8c9b443 100644 --- a/sitio/.prettierrc +++ b/sitio/.prettierrc @@ -1,8 +1,4 @@ { - "useTabs": true, - "singleQuote": true, - "trailingComma": "none", - "printWidth": 100, "plugins": ["prettier-plugin-svelte", "prettier-plugin-tailwindcss"], "overrides": [ { diff --git a/sitio/package.json b/sitio/package.json index 7b3ce4a..d26f9a4 100644 --- a/sitio/package.json +++ b/sitio/package.json @@ -1,32 +1,32 @@ { - "name": "sitio", - "version": "0.0.1", - "private": true, - "scripts": { - "dev": "vite dev", - "build": "vite build", - "preview": "vite preview", - "check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json", - "check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch", - "lint": "prettier --check .", - "format": "prettier --write ." - }, - "devDependencies": { - "@sveltejs/adapter-auto": "^3.0.0", - "@sveltejs/kit": "^2.0.0", - "@sveltejs/vite-plugin-svelte": "^3.0.0", - "autoprefixer": "^10.4.16", - "postcss": "^8.4.32", - "postcss-load-config": "^5.0.2", - "prettier": "^3.1.1", - "prettier-plugin-svelte": "^3.1.2", - "prettier-plugin-tailwindcss": "^0.5.9", - "svelte": "^4.2.7", - "svelte-check": "^3.6.0", - "tailwindcss": "^3.3.6", - "tslib": "^2.4.1", - "typescript": "^5.0.0", - "vite": "^5.0.3" - }, - "type": "module" + "name": "sitio", + "version": "0.0.1", + "private": true, + "scripts": { + "dev": "vite dev", + "build": "vite build", + "preview": "vite preview", + "check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json", + "check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch", + "lint": "prettier --check .", + "format": "prettier --write ." + }, + "devDependencies": { + "@sveltejs/adapter-auto": "^3.0.0", + "@sveltejs/kit": "^2.0.0", + "@sveltejs/vite-plugin-svelte": "^3.0.0", + "autoprefixer": "^10.4.16", + "postcss": "^8.4.32", + "postcss-load-config": "^5.0.2", + "prettier": "^3.1.1", + "prettier-plugin-svelte": "^3.1.2", + "prettier-plugin-tailwindcss": "^0.5.9", + "svelte": "^4.2.7", + "svelte-check": "^3.6.0", + "tailwindcss": "^3.3.6", + "tslib": "^2.4.1", + "typescript": "^5.0.0", + "vite": "^5.0.3" + }, + "type": "module" } diff --git a/sitio/postcss.config.cjs b/sitio/postcss.config.cjs index fe10e55..e48cff5 100644 --- a/sitio/postcss.config.cjs +++ b/sitio/postcss.config.cjs @@ -1,13 +1,13 @@ -const tailwindcss = require('tailwindcss'); -const autoprefixer = require('autoprefixer'); +const tailwindcss = require("tailwindcss"); +const autoprefixer = require("autoprefixer"); const config = { - plugins: [ - //Some plugins, like tailwindcss/nesting, need to run before Tailwind, - tailwindcss(), - //But others, like autoprefixer, need to run after, - autoprefixer - ] + plugins: [ + //Some plugins, like tailwindcss/nesting, need to run before Tailwind, + tailwindcss(), + //But others, like autoprefixer, need to run after, + autoprefixer, + ], }; module.exports = config; diff --git a/sitio/src/app.d.ts b/sitio/src/app.d.ts index 743f07b..ede601a 100644 --- a/sitio/src/app.d.ts +++ b/sitio/src/app.d.ts @@ -1,13 +1,13 @@ // See https://kit.svelte.dev/docs/types#app // for information about these interfaces declare global { - namespace App { - // interface Error {} - // interface Locals {} - // interface PageData {} - // interface PageState {} - // interface Platform {} - } + namespace App { + // interface Error {} + // interface Locals {} + // interface PageData {} + // interface PageState {} + // interface Platform {} + } } export {}; diff --git a/sitio/src/app.html b/sitio/src/app.html index 77a5ff5..84ffad1 100644 --- a/sitio/src/app.html +++ b/sitio/src/app.html @@ -1,12 +1,12 @@ - - - - - %sveltekit.head% - - -
%sveltekit.body%
- + + + + + %sveltekit.head% + + +
%sveltekit.body%
+ diff --git a/sitio/src/routes/+layout.svelte b/sitio/src/routes/+layout.svelte index 17abf18..bde3404 100644 --- a/sitio/src/routes/+layout.svelte +++ b/sitio/src/routes/+layout.svelte @@ -1,5 +1,5 @@ diff --git a/sitio/src/routes/+page.svelte b/sitio/src/routes/+page.svelte index 5982b0a..4ba7b2a 100644 --- a/sitio/src/routes/+page.svelte +++ b/sitio/src/routes/+page.svelte @@ -1,2 +1,4 @@

Welcome to SvelteKit

-

Visit kit.svelte.dev to read the documentation

+

+ Visit kit.svelte.dev to read the documentation +

diff --git a/sitio/svelte.config.js b/sitio/svelte.config.js index c9c19b0..e941994 100644 --- a/sitio/svelte.config.js +++ b/sitio/svelte.config.js @@ -1,18 +1,18 @@ -import adapter from '@sveltejs/adapter-auto'; -import { vitePreprocess } from '@sveltejs/vite-plugin-svelte'; +import adapter from "@sveltejs/adapter-auto"; +import { vitePreprocess } from "@sveltejs/vite-plugin-svelte"; /** @type {import('@sveltejs/kit').Config} */ const config = { - // Consult https://kit.svelte.dev/docs/integrations#preprocessors - // for more information about preprocessors - preprocess: [vitePreprocess({})], + // Consult https://kit.svelte.dev/docs/integrations#preprocessors + // for more information about preprocessors + preprocess: [vitePreprocess({})], - kit: { - // adapter-auto only supports some environments, see https://kit.svelte.dev/docs/adapter-auto for a list. - // If your environment is not supported or you settled on a specific environment, switch out the adapter. - // See https://kit.svelte.dev/docs/adapters for more information about adapters. - adapter: adapter() - } + kit: { + // adapter-auto only supports some environments, see https://kit.svelte.dev/docs/adapter-auto for a list. + // If your environment is not supported or you settled on a specific environment, switch out the adapter. + // See https://kit.svelte.dev/docs/adapters for more information about adapters. + adapter: adapter(), + }, }; export default config; diff --git a/sitio/tailwind.config.cjs b/sitio/tailwind.config.cjs index a2629b6..75fd684 100644 --- a/sitio/tailwind.config.cjs +++ b/sitio/tailwind.config.cjs @@ -1,12 +1,12 @@ /** @type {import('tailwindcss').Config}*/ const config = { - content: ['./src/**/*.{html,js,svelte,ts}'], + content: ["./src/**/*.{html,js,svelte,ts}"], - theme: { - extend: {} - }, + theme: { + extend: {}, + }, - plugins: [] + plugins: [], }; module.exports = config; diff --git a/sitio/tsconfig.json b/sitio/tsconfig.json index 82081ab..34aadc0 100644 --- a/sitio/tsconfig.json +++ b/sitio/tsconfig.json @@ -1,18 +1,18 @@ { - "extends": "./.svelte-kit/tsconfig.json", - "compilerOptions": { - "allowJs": true, - "checkJs": true, - "esModuleInterop": true, - "forceConsistentCasingInFileNames": true, - "resolveJsonModule": true, - "skipLibCheck": true, - "sourceMap": true, - "strict": true, - "moduleResolution": "bundler" - } - // Path aliases are handled by https://kit.svelte.dev/docs/configuration#alias - // - // If you want to overwrite includes/excludes, make sure to copy over the relevant includes/excludes - // from the referenced tsconfig.json - TypeScript does not merge them in + "extends": "./.svelte-kit/tsconfig.json", + "compilerOptions": { + "allowJs": true, + "checkJs": true, + "esModuleInterop": true, + "forceConsistentCasingInFileNames": true, + "resolveJsonModule": true, + "skipLibCheck": true, + "sourceMap": true, + "strict": true, + "moduleResolution": "bundler" + } + // Path aliases are handled by https://kit.svelte.dev/docs/configuration#alias + // + // If you want to overwrite includes/excludes, make sure to copy over the relevant includes/excludes + // from the referenced tsconfig.json - TypeScript does not merge them in } diff --git a/sitio/vite.config.ts b/sitio/vite.config.ts index bbf8c7d..80864b9 100644 --- a/sitio/vite.config.ts +++ b/sitio/vite.config.ts @@ -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()], });