Skip to content

Commit

Permalink
- Packages updated (sveltekit 2/vite 5 compatibility)
Browse files Browse the repository at this point in the history
  • Loading branch information
howesteve committed Jan 20, 2024
1 parent 69d5b84 commit 586b13c
Show file tree
Hide file tree
Showing 21 changed files with 736 additions and 659 deletions.
208 changes: 91 additions & 117 deletions .svelte-kit/ambient.d.ts

Large diffs are not rendered by default.

7 changes: 5 additions & 2 deletions .svelte-kit/generated/client/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,20 @@ export { matchers } from './matchers.js';

export const nodes = [
() => import('./nodes/0'),
() => import('./nodes/1')
() => import('./nodes/1'),
() => import('./nodes/2')
];

export const server_loads = [];

export const dictionary = {

"/": [2]
};

export const hooks = {
handleError: (({ error }) => { console.error(error) }),

reroute: (() => {})
};

export { default as root } from '../root.svelte';
2 changes: 1 addition & 1 deletion .svelte-kit/generated/client/nodes/0.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion .svelte-kit/generated/client/nodes/1.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 6 additions & 3 deletions .svelte-kit/generated/root.svelte
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
<!-- This file is generated by @sveltejs/kit — do not edit it! -->

<script>
import { setContext, afterUpdate, onMount } from 'svelte';
import { setContext, afterUpdate, onMount, tick } from 'svelte';
import { browser } from '$app/environment';
// stores
export let stores;
export let page;
export let constructors;
export let components = [];
export let form;
Expand All @@ -28,7 +29,9 @@
const unsubscribe = stores.page.subscribe(() => {
if (mounted) {
navigated = true;
title = document.title || 'untitled page';
tick().then(() => {
title = document.title || 'untitled page';
});
}
});
Expand Down
23 changes: 14 additions & 9 deletions .svelte-kit/generated/server/internal.js
Original file line number Diff line number Diff line change
@@ -1,29 +1,34 @@

import root from '../root.svelte';
import { set_building } from '__sveltekit/environment';
import { set_building, set_prerendering } from '__sveltekit/environment';
import { set_assets } from '__sveltekit/paths';
import { set_private_env, set_public_env } from '../../../node_modules/.pnpm/@sveltejs+kit@1.18.0_svelte@3.59.1_vite@4.3.8/node_modules/@sveltejs/kit/src/runtime/shared-server.js';
import { set_manifest, set_read_implementation } from '__sveltekit/server';
import { set_private_env, set_public_env, set_safe_public_env } from '../../../node_modules/.pnpm/@sveltejs+kit@2.4.1_@sveltejs+vite-plugin-svelte@3.0.1_svelte@4.2.9_vite@5.0.12/node_modules/@sveltejs/kit/src/runtime/shared-server.js';

export const options = {
app_dir: "_app",
app_template_contains_nonce: false,
csp: {"mode":"auto","directives":{"upgrade-insecure-requests":false,"block-all-mixed-content":false},"reportOnly":{"upgrade-insecure-requests":false,"block-all-mixed-content":false}},
csrf_check_origin: true,
track_server_fetches: false,
embedded: false,
env_public_prefix: 'PUBLIC_',
env_private_prefix: '',
hooks: null, // added lazily, via `get_hooks`
preload_strategy: "modulepreload",
root,
service_worker: false,
templates: {
app: ({ head, body, assets, nonce, env }) => "<!DOCTYPE html>\n<html lang=\"en\">\n\t<head>\n\t\t<meta charset=\"utf-8\" />\n\t\t<link rel=\"icon\" href=\"" + assets + "/favicon.png\" />\n\t\t<meta name=\"viewport\" content=\"width=device-width\" />\n\t\t" + head + "\n\t</head>\n\t<body data-sveltekit-preload-data=\"hover\">\n\t\t<div style=\"display: contents\">" + body + "</div>\n\t</body>\n</html>\n",
error: ({ status, message }) => "<!DOCTYPE html>\n<html lang=\"en\">\n\t<head>\n\t\t<meta charset=\"utf-8\" />\n\t\t<title>" + message + "</title>\n\n\t\t<style>\n\t\t\tbody {\n\t\t\t\t--bg: white;\n\t\t\t\t--fg: #222;\n\t\t\t\t--divider: #ccc;\n\t\t\t\tbackground: var(--bg);\n\t\t\t\tcolor: var(--fg);\n\t\t\t\tfont-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen,\n\t\t\t\t\tUbuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;\n\t\t\t\tdisplay: flex;\n\t\t\t\talign-items: center;\n\t\t\t\tjustify-content: center;\n\t\t\t\theight: 100vh;\n\t\t\t}\n\n\t\t\t.error {\n\t\t\t\tdisplay: flex;\n\t\t\t\talign-items: center;\n\t\t\t\tmax-width: 32rem;\n\t\t\t\tmargin: 0 1rem;\n\t\t\t}\n\n\t\t\t.status {\n\t\t\t\tfont-weight: 200;\n\t\t\t\tfont-size: 3rem;\n\t\t\t\tline-height: 1;\n\t\t\t\tposition: relative;\n\t\t\t\ttop: -0.05rem;\n\t\t\t}\n\n\t\t\t.message {\n\t\t\t\tborder-left: 1px solid var(--divider);\n\t\t\t\tpadding: 0 0 0 1rem;\n\t\t\t\tmargin: 0 0 0 1rem;\n\t\t\t\tmin-height: 2.5rem;\n\t\t\t\tdisplay: flex;\n\t\t\t\talign-items: center;\n\t\t\t}\n\n\t\t\t.message h1 {\n\t\t\t\tfont-weight: 400;\n\t\t\t\tfont-size: 1em;\n\t\t\t\tmargin: 0;\n\t\t\t}\n\n\t\t\t@media (prefers-color-scheme: dark) {\n\t\t\t\tbody {\n\t\t\t\t\t--bg: #222;\n\t\t\t\t\t--fg: #ddd;\n\t\t\t\t\t--divider: #666;\n\t\t\t\t}\n\t\t\t}\n\t\t</style>\n\t</head>\n\t<body>\n\t\t<div class=\"error\">\n\t\t\t<span class=\"status\">" + status + "</span>\n\t\t\t<div class=\"message\">\n\t\t\t\t<h1>" + message + "</h1>\n\t\t\t</div>\n\t\t</div>\n\t</body>\n</html>\n"
app: ({ head, body, assets, nonce, env }) => "<!doctype html>\n<html lang=\"en\">\n\t<head>\n\t\t<meta charset=\"utf-8\" />\n\t\t<link rel=\"icon\" href=\"" + assets + "/favicon.png\" />\n\t\t<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\" />\n\t\t" + head + "\n\t</head>\n\t<body data-sveltekit-preload-data=\"hover\">\n\t\t<div>" + body + "</div>\n\t</body>\n</html>\n",
error: ({ status, message }) => "<!doctype html>\n<html lang=\"en\">\n\t<head>\n\t\t<meta charset=\"utf-8\" />\n\t\t<title>" + message + "</title>\n\n\t\t<style>\n\t\t\tbody {\n\t\t\t\t--bg: white;\n\t\t\t\t--fg: #222;\n\t\t\t\t--divider: #ccc;\n\t\t\t\tbackground: var(--bg);\n\t\t\t\tcolor: var(--fg);\n\t\t\t\tfont-family:\n\t\t\t\t\tsystem-ui,\n\t\t\t\t\t-apple-system,\n\t\t\t\t\tBlinkMacSystemFont,\n\t\t\t\t\t'Segoe UI',\n\t\t\t\t\tRoboto,\n\t\t\t\t\tOxygen,\n\t\t\t\t\tUbuntu,\n\t\t\t\t\tCantarell,\n\t\t\t\t\t'Open Sans',\n\t\t\t\t\t'Helvetica Neue',\n\t\t\t\t\tsans-serif;\n\t\t\t\tdisplay: flex;\n\t\t\t\talign-items: center;\n\t\t\t\tjustify-content: center;\n\t\t\t\theight: 100vh;\n\t\t\t\tmargin: 0;\n\t\t\t}\n\n\t\t\t.error {\n\t\t\t\tdisplay: flex;\n\t\t\t\talign-items: center;\n\t\t\t\tmax-width: 32rem;\n\t\t\t\tmargin: 0 1rem;\n\t\t\t}\n\n\t\t\t.status {\n\t\t\t\tfont-weight: 200;\n\t\t\t\tfont-size: 3rem;\n\t\t\t\tline-height: 1;\n\t\t\t\tposition: relative;\n\t\t\t\ttop: -0.05rem;\n\t\t\t}\n\n\t\t\t.message {\n\t\t\t\tborder-left: 1px solid var(--divider);\n\t\t\t\tpadding: 0 0 0 1rem;\n\t\t\t\tmargin: 0 0 0 1rem;\n\t\t\t\tmin-height: 2.5rem;\n\t\t\t\tdisplay: flex;\n\t\t\t\talign-items: center;\n\t\t\t}\n\n\t\t\t.message h1 {\n\t\t\t\tfont-weight: 400;\n\t\t\t\tfont-size: 1em;\n\t\t\t\tmargin: 0;\n\t\t\t}\n\n\t\t\t@media (prefers-color-scheme: dark) {\n\t\t\t\tbody {\n\t\t\t\t\t--bg: #222;\n\t\t\t\t\t--fg: #ddd;\n\t\t\t\t\t--divider: #666;\n\t\t\t\t}\n\t\t\t}\n\t\t</style>\n\t</head>\n\t<body>\n\t\t<div class=\"error\">\n\t\t\t<span class=\"status\">" + status + "</span>\n\t\t\t<div class=\"message\">\n\t\t\t\t<h1>" + message + "</h1>\n\t\t\t</div>\n\t\t</div>\n\t</body>\n</html>\n"
},
version_hash: "jqgegu"
version_hash: "1m2kkxk"
};

export function get_hooks() {
return {};
export async function get_hooks() {
return {


};
}

export { set_assets, set_building, set_private_env, set_public_env };
export { set_assets, set_building, set_manifest, set_prerendering, set_private_env, set_public_env, set_read_implementation, set_safe_public_env };
25 changes: 25 additions & 0 deletions .svelte-kit/non-ambient.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@

// this file is generated — do not edit it


declare module "svelte/elements" {
export interface HTMLAttributes<T> {
'data-sveltekit-keepfocus'?: true | '' | 'off' | undefined | null;
'data-sveltekit-noscroll'?: true | '' | 'off' | undefined | null;
'data-sveltekit-preload-code'?:
| true
| ''
| 'eager'
| 'viewport'
| 'hover'
| 'tap'
| 'off'
| undefined
| null;
'data-sveltekit-preload-data'?: true | '' | 'hover' | 'tap' | 'off' | undefined | null;
'data-sveltekit-reload'?: true | '' | 'off' | undefined | null;
'data-sveltekit-replacestate'?: true | '' | 'off' | undefined | null;
}
}

export {};
15 changes: 5 additions & 10 deletions .svelte-kit/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,22 +12,21 @@
"..",
"./types"
],
"importsNotUsedAsValues": "error",
"verbatimModuleSyntax": true,
"isolatedModules": true,
"preserveValueImports": true,
"lib": [
"esnext",
"DOM",
"DOM.Iterable"
],
"moduleResolution": "node",
"moduleResolution": "bundler",
"module": "esnext",
"noEmit": true,
"target": "esnext",
"ignoreDeprecations": "5.0"
"target": "esnext"
},
"include": [
"ambient.d.ts",
"non-ambient.d.ts",
"./types/**/$types.d.ts",
"../vite.config.js",
"../vite.config.ts",
Expand All @@ -39,10 +38,6 @@
"../tests/**/*.svelte"
],
"exclude": [
"../node_modules/**",
"./[!ambient.d.ts]**",
"../src/service-worker.js",
"../src/service-worker.ts",
"../src/service-worker.d.ts"
"../node_modules/**"
]
}
4 changes: 3 additions & 1 deletion .svelte-kit/types/src/routes/$types.d.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
import type * as Kit from '@sveltejs/kit';

type Expand<T> = T extends infer O ? { [K in keyof O]: O[K] } : never;
type RouteParams = { }
// @ts-ignore
type MatcherParam<M> = M extends (param : string) => param is infer U ? U extends string ? U : string : string;
type RouteParams = { };
type RouteId = '/';
type MaybeWithVoid<T> = {} extends T ? T | void : T;
export type RequiredKeys<T> = { [K in keyof T]-?: {} extends { [P in K]: T[K] } ? never : K; }[keyof T];
Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<!-- markdownlint-disable MD024 -->

# Change Log
# Changelog

All notable changes to [Elegua](http://github.com/howesteve/elegua) will be documented in this file.

Expand Down
20 changes: 11 additions & 9 deletions index.html
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
<!DOCTYPE html>
<!doctype html>
<html lang="en">
<head prefix="og: https://ogp.me/ns#">
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
</head>
<body>
<div id="app"></div>
<script type="module" src="./src/index.ts"></script>
</body>
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Vite + Svelte + TS</title>
</head>
<body>
<div id="app"></div>
<script type="module" src="/src/index.ts"></script>
</body>
</html>
38 changes: 20 additions & 18 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "elegua",
"version": "2.2.2",
"version": "2.2.3",
"private": false,
"homepage": "https://github.com/howesteve/elegua",
"bugs": {
Expand All @@ -21,7 +21,7 @@
"lint": "prettier --plugin-search-dir . --check . && eslint .",
"format": "prettier --plugin-search-dir . --write .",
"publish": "pnpm publish --access public --no-git-checks",
"release:pre": "ts-node --esm updateREADME.ts",
"release:pre": "node --no-warnings --experimental-specifier-resolution=node --loader ts-node/esm updateREADME.ts",
"release": "pnpm run clean;pnpm run release:pre && pnpm run build && pnpm run publish"
},
"publishConfig": {
Expand All @@ -47,26 +47,28 @@
"url": "https://github.com/howesteve/elegua"
},
"devDependencies": {
"@sveltejs/adapter-auto": "^2.1.1",
"@sveltejs/kit": "^1.27.6",
"@sveltejs/package": "^2.2.3",
"@sveltejs/adapter-auto": "^3.1.1",
"@sveltejs/kit": "^2.4.1",
"@sveltejs/package": "^2.2.6",
"@sveltejs/vite-plugin-svelte": "^3.0.1",
"@swc/core": "^1.3.99",
"@types/node": "^20.10.0",
"@swc/core": "^1.3.104",
"@tsconfig/svelte": "^5.0.2",
"@types/node": "^20.11.5",
"@types/sloc": "^0.2.3",
"@typescript-eslint/eslint-plugin": "^6.13.1",
"@typescript-eslint/parser": "^6.13.1",
"elegua": "^2.2.1",
"eslint": "^8.54.0",
"eslint-config-prettier": "^9.0.0",
"@typescript-eslint/eslint-plugin": "^6.19.0",
"@typescript-eslint/parser": "^6.19.0",
"elegua": "^2.2.2",
"eslint": "^8.56.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-svelte": "^2.35.1",
"prettier": "^3.1.0",
"sloc": "^0.3.0",
"svelte": "^4.2.7",
"svelte-check": "^3.6.2",
"prettier": "^3.2.4",
"sloc": "^0.3.1",
"svelte": "^4.2.9",
"svelte-check": "^3.6.3",
"ts-node": "^10.9.2",
"tslib": "^2.6.2",
"typescript": "^5.3.2",
"vite": "^5.0.3"
"typescript": "^5.3.3",
"vite": "^5.0.12"
},
"exports": {
".": {
Expand Down
Loading

0 comments on commit 586b13c

Please sign in to comment.