aboutsummaryrefslogtreecommitdiffstats
path: root/app/src/hooks.server.ts
diff options
context:
space:
mode:
authorMatt Strapp <matt@mattstrapp.net>2023-09-15 14:43:51 -0500
committerMatt Strapp <matt@mattstrapp.net>2023-09-15 14:43:51 -0500
commit9427a9bf942f462b52b74fd9209b7dc2aa5f6265 (patch)
tree490876e821a8775f1657e7fcabbc6e4740dc50db /app/src/hooks.server.ts
parentt r a n s p a r e n c y (diff)
downloadtrinkets-9427a9bf942f462b52b74fd9209b7dc2aa5f6265.tar
trinkets-9427a9bf942f462b52b74fd9209b7dc2aa5f6265.tar.gz
trinkets-9427a9bf942f462b52b74fd9209b7dc2aa5f6265.tar.bz2
trinkets-9427a9bf942f462b52b74fd9209b7dc2aa5f6265.tar.lz
trinkets-9427a9bf942f462b52b74fd9209b7dc2aa5f6265.tar.xz
trinkets-9427a9bf942f462b52b74fd9209b7dc2aa5f6265.tar.zst
trinkets-9427a9bf942f462b52b74fd9209b7dc2aa5f6265.zip
make eslint and prettier happy
Signed-off-by: Matt Strapp <matt@mattstrapp.net>
Diffstat (limited to 'app/src/hooks.server.ts')
-rw-r--r--app/src/hooks.server.ts54
1 files changed, 27 insertions, 27 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;
+ }
+ }
+ });
+}