Formatting with trailing comma

This commit is contained in:
Valentin Brandl 2024-08-17 15:45:52 +02:00
parent 48948a180a
commit cfb5564830
Signed by: vbrandl
GPG Key ID: CAD4DA1A789125F9
9 changed files with 23 additions and 23 deletions

View File

@ -1,7 +1,7 @@
{
"useTabs": true,
"singleQuote": true,
"trailingComma": "none",
"trailingComma": "es5",
"printWidth": 100,
"plugins": ["prettier-plugin-svelte"],
"overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }]

View File

@ -15,19 +15,19 @@ export default [
languageOptions: {
globals: {
...globals.browser,
...globals.node
}
}
...globals.node,
},
},
},
{
files: ['**/*.svelte'],
languageOptions: {
parserOptions: {
parser: ts.parser
}
}
parser: ts.parser,
},
},
},
{
ignores: ['build/', '.svelte-kit/', 'dist/']
}
ignores: ['build/', '.svelte-kit/', 'dist/'],
},
];

View File

@ -1,4 +1,4 @@
{
$schema: 'https://docs.renovatebot.com/renovate-schema.json',
extends: ['local>renovate-bot/renovate-config']
extends: ['local>renovate-bot/renovate-config'],
}

View File

@ -17,7 +17,7 @@ export async function handle({ event, resolve }) {
route: event.route.id,
method: event.request.method,
userAgent: event.request.headers.get('user-agent'),
clientIP: event.getClientAddress()
clientIP: event.getClientAddress(),
};
if (fromRequest) {
log.trace(context, 'using incomming request-id');
@ -36,7 +36,7 @@ export async function handle({ event, resolve }) {
executionTime: `${executionTime}ms`,
status: response.status,
size: response.headers.get('content-length'),
...context
...context,
},
'finished request'
);

View File

@ -6,7 +6,7 @@ import type { MaybePromise } from '@sveltejs/kit';
export const log = bunyan.createLogger({
name: 'fotochallenge',
level: process.env.NODE_ENV === 'production' ? 'info' : 'debug',
src: true
src: true,
});
function safePath(basePath: string, name: string): boolean {

View File

@ -69,7 +69,7 @@ export const actions = {
});
return {
success: true
success: true,
};
}
},
};

View File

@ -13,7 +13,7 @@
const siPrefixes = new Map([
[1_000_000, 'M'],
[1_000, 'k']
[1_000, 'k'],
]);
const fileSize = (files: FileList) => {
const size = Array.from(files)

View File

@ -11,8 +11,8 @@ const config = {
// 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()
}
adapter: adapter(),
},
};
export default config;

View File

@ -5,14 +5,14 @@ export default defineConfig({
plugins: [sveltekit()],
test: {
include: ['src/**/*.{test,spec}.{js,ts}']
include: ['src/**/*.{test,spec}.{js,ts}'],
},
css: {
preprocessorOptions: {
scss: {
additionalData: '@use "src/variables.scss" as *;'
}
}
}
additionalData: '@use "src/variables.scss" as *;',
},
},
},
});