aboutsummaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--app/src/hooks.server.ts54
-rw-r--r--app/src/routes/crc32/+page.svelte2
-rw-r--r--app/vite.config.ts8
3 files changed, 32 insertions, 32 deletions
diff --git a/app/src/hooks.server.ts b/app/src/hooks.server.ts
index aaf2757..bf7121a 100644
--- a/app/src/hooks.server.ts
+++ b/app/src/hooks.server.ts
@@ -2,35 +2,35 @@ import { minify } from 'html-minifier-terser';
import { building } from '$app/environment';
const minification_options = {
- collapseBooleanAttributes: true,
- collapseWhitespace: true,
- conservativeCollapse: true,
- decodeEntities: true,
- html5: true,
- ignoreCustomComments: [/^#/],
- minifyCSS: true,
- minifyJS: true,
- minifyURLs: true,
- removeAttributeQuotes: true,
- removeComments: false, // some hydration code needs comments, so leave them in
- removeOptionalTags: true,
- removeRedundantAttributes: true,
- removeScriptTypeAttributes: true,
- removeStyleLinkTypeAttributes: true,
- sortAttributes: true,
- sortClassName: true
+ collapseBooleanAttributes: true,
+ collapseWhitespace: true,
+ conservativeCollapse: true,
+ decodeEntities: true,
+ html5: true,
+ ignoreCustomComments: [/^#/],
+ minifyCSS: true,
+ minifyJS: true,
+ minifyURLs: true,
+ removeAttributeQuotes: true,
+ removeComments: false, // some hydration code needs comments, so leave them in
+ removeOptionalTags: true,
+ removeRedundantAttributes: true,
+ removeScriptTypeAttributes: true,
+ removeStyleLinkTypeAttributes: true,
+ sortAttributes: true,
+ sortClassName: true
};
/** @type {import('@sveltejs/kit').Handle} */
export async function handle({ event, resolve }) {
- let page = '';
+ let page = '';
- return resolve(event, {
- transformPageChunk: ({ html, done }) => {
- page += html;
- if (done) {
- return building ? minify(page, minification_options) : page;
- }
- }
- });
-} \ No newline at end of file
+ return resolve(event, {
+ transformPageChunk: ({ html, done }) => {
+ page += html;
+ if (done) {
+ return building ? minify(page, minification_options) : page;
+ }
+ }
+ });
+}
diff --git a/app/src/routes/crc32/+page.svelte b/app/src/routes/crc32/+page.svelte
index 18cc515..86b614d 100644
--- a/app/src/routes/crc32/+page.svelte
+++ b/app/src/routes/crc32/+page.svelte
@@ -15,7 +15,7 @@
onMount(async () => {
worker = new (await import('$lib/ts/crc32.worker?worker')).default();
- worker.onmessage = (e: MessageEvent<Number>) => {
+ worker.onmessage = (e: MessageEvent<number>) => {
disableInput = false;
console.log(e.data);
};
diff --git a/app/vite.config.ts b/app/vite.config.ts
index c31da3b..b749653 100644
--- a/app/vite.config.ts
+++ b/app/vite.config.ts
@@ -36,13 +36,13 @@ export default defineConfig({
type: 'image/png'
}
],
- id: "/",
- theme_color: '#000000',
+ id: '/',
+ theme_color: '#000000'
},
registerType: 'autoUpdate',
workbox: {
- globPatterns: [ 'client/**/*.{js,css,html,svg}' ],
- cleanupOutdatedCaches: true,
+ globPatterns: ['client/**/*.{js,css,html,svg}'],
+ cleanupOutdatedCaches: true
}
})
]