@sveltejs/kit 1.0.0-next.334 → 1.0.0-next.335
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/server/index.js +2 -2
- package/dist/chunks/index.js +2 -2
- package/dist/cli.js +2 -2
- package/package.json +1 -1
- package/types/ambient.d.ts +9 -1
package/assets/server/index.js
CHANGED
|
@@ -1242,7 +1242,7 @@ async function render_response({
|
|
|
1242
1242
|
const init_app = `
|
|
1243
1243
|
import { start } from ${s(options.prefix + options.manifest._.entry.file)};
|
|
1244
1244
|
start({
|
|
1245
|
-
target: document.querySelector('[data-hydrate="${target}"]').parentNode,
|
|
1245
|
+
target: document.querySelector('[data-sveltekit-hydrate="${target}"]').parentNode,
|
|
1246
1246
|
paths: ${s(options.paths)},
|
|
1247
1247
|
session: ${try_serialize($session, (error) => {
|
|
1248
1248
|
throw new Error(`Failed to serialize session data: ${error.message}`);
|
|
@@ -1327,7 +1327,7 @@ async function render_response({
|
|
|
1327
1327
|
.map((dep) => `\n\t<link rel="modulepreload" href="${options.prefix + dep}">`)
|
|
1328
1328
|
.join('');
|
|
1329
1329
|
|
|
1330
|
-
const attributes = ['type="module"', `data-hydrate="${target}"`];
|
|
1330
|
+
const attributes = ['type="module"', `data-sveltekit-hydrate="${target}"`];
|
|
1331
1331
|
|
|
1332
1332
|
csp.add_script(init_app);
|
|
1333
1333
|
|
package/dist/chunks/index.js
CHANGED
|
@@ -461,9 +461,9 @@ async function dev({ cwd, port, host, https, config }) {
|
|
|
461
461
|
path__default.resolve(cwd, 'node_modules'),
|
|
462
462
|
path__default.resolve(vite.searchForWorkspaceRoot(cwd), 'node_modules')
|
|
463
463
|
])
|
|
464
|
-
]
|
|
465
|
-
port: 3000
|
|
464
|
+
]
|
|
466
465
|
},
|
|
466
|
+
port: 3000,
|
|
467
467
|
strictPort: true
|
|
468
468
|
}
|
|
469
469
|
},
|
package/dist/cli.js
CHANGED
|
@@ -870,7 +870,7 @@ async function launch(port, https, base) {
|
|
|
870
870
|
exec(`${cmd} ${https ? 'https' : 'http'}://localhost:${port}${base}`);
|
|
871
871
|
}
|
|
872
872
|
|
|
873
|
-
const prog = sade('svelte-kit').version('1.0.0-next.
|
|
873
|
+
const prog = sade('svelte-kit').version('1.0.0-next.335');
|
|
874
874
|
|
|
875
875
|
prog
|
|
876
876
|
.command('dev')
|
|
@@ -1049,7 +1049,7 @@ async function check_port(port) {
|
|
|
1049
1049
|
function welcome({ port, host, https, open, base, loose, allow, cwd }) {
|
|
1050
1050
|
if (open) launch(port, https, base);
|
|
1051
1051
|
|
|
1052
|
-
console.log($.bold().cyan(`\n SvelteKit v${'1.0.0-next.
|
|
1052
|
+
console.log($.bold().cyan(`\n SvelteKit v${'1.0.0-next.335'}\n`));
|
|
1053
1053
|
|
|
1054
1054
|
const protocol = https ? 'https:' : 'http:';
|
|
1055
1055
|
const exposed = typeof host !== 'undefined' && host !== 'localhost' && host !== '127.0.0.1';
|
package/package.json
CHANGED
package/types/ambient.d.ts
CHANGED
|
@@ -15,7 +15,15 @@
|
|
|
15
15
|
* }
|
|
16
16
|
* ```
|
|
17
17
|
*
|
|
18
|
-
* By populating these interfaces, you will gain type safety when using `event.locals`, `event.platform`, `session` and `stuff
|
|
18
|
+
* By populating these interfaces, you will gain type safety when using `event.locals`, `event.platform`, `session` and `stuff`.
|
|
19
|
+
*
|
|
20
|
+
* Note that since it's an ambient declaration file, you can't use `import` statements — instead, use the `import(...)` function:
|
|
21
|
+
*
|
|
22
|
+
* ```ts
|
|
23
|
+
* interface Locals {
|
|
24
|
+
* user: import('$lib/types').User;
|
|
25
|
+
* }
|
|
26
|
+
* ```
|
|
19
27
|
*/
|
|
20
28
|
declare namespace App {
|
|
21
29
|
/**
|