Skip to content

Commit 9f4a28d

Browse files
committed
Docs starting point
1 parent 6af4cd2 commit 9f4a28d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+1511
-1200
lines changed

.eslintignore

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
.DS_Store
2+
node_modules
3+
/build
4+
/.svelte-kit
5+
/package
6+
.env
7+
.env.*
8+
!.env.example
9+
10+
# Ignore files for PNPM, NPM and YARN
11+
pnpm-lock.yaml
12+
package-lock.json
13+
yarn.lock

.eslintrc.cjs

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
module.exports = {
2+
root: true,
3+
parser: '@typescript-eslint/parser',
4+
extends: ['eslint:recommended', 'plugin:@typescript-eslint/recommended', 'prettier'],
5+
plugins: ['svelte3', '@typescript-eslint'],
6+
ignorePatterns: ['*.cjs'],
7+
overrides: [{ files: ['*.svelte'], processor: 'svelte3/svelte3' }],
8+
settings: {
9+
'svelte3/typescript': () => require('typescript')
10+
},
11+
parserOptions: {
12+
sourceType: 'module',
13+
ecmaVersion: 2020
14+
},
15+
env: {
16+
browser: true,
17+
es2017: true,
18+
node: true
19+
}
20+
};

.gitignore

Lines changed: 9 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,10 @@
1-
# Logs
2-
logs
3-
*.log
4-
npm-debug.log*
5-
yarn-debug.log*
6-
yarn-error.log*
7-
pnpm-debug.log*
8-
lerna-debug.log*
9-
10-
node_modules
11-
dist
12-
dist-ssr
13-
*.local
14-
15-
# Editor directories and files
16-
.vscode/*
17-
!.vscode/extensions.json
18-
.idea
191
.DS_Store
20-
*.suo
21-
*.ntvs*
22-
*.njsproj
23-
*.sln
24-
*.sw?
2+
node_modules
3+
/build
4+
/.svelte-kit
5+
/package
6+
.env
7+
.env.*
8+
!.env.example
9+
vite.config.js.timestamp-*
10+
vite.config.ts.timestamp-*

.npmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
engine-strict=true

.prettierignore

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
.DS_Store
2+
node_modules
3+
/build
4+
/.svelte-kit
5+
/package
6+
.env
7+
.env.*
8+
!.env.example
9+
10+
# Ignore files for PNPM, NPM and YARN
11+
pnpm-lock.yaml
12+
package-lock.json
13+
yarn.lock

.prettierrc

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"useTabs": true,
3+
"singleQuote": true,
4+
"trailingComma": "none",
5+
"printWidth": 100,
6+
"plugins": ["prettier-plugin-svelte"],
7+
"pluginSearchDirs": ["."],
8+
"overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }]
9+
}

.svelte-kit/ambient.d.ts

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ declare module '$env/static/private' {
3939
export const npm_config_noproxy: string;
4040
export const HOME: string;
4141
export const CHROME_DESKTOP: string;
42+
export const OLDPWD: string;
4243
export const TERM_PROGRAM_VERSION: string;
4344
export const DESKTOP_SESSION: string;
4445
export const npm_package_json: string;
@@ -54,6 +55,7 @@ declare module '$env/static/private' {
5455
export const HOMEBREW_SHELLENV_PREFIX: string;
5556
export const SYSTEMD_EXEC_PID: string;
5657
export const DBUS_SESSION_BUS_ADDRESS: string;
58+
export const npm_config_engine_strict: string;
5759
export const COLORTERM: string;
5860
export const GIO_LAUNCHED_DESKTOP_FILE_PID: string;
5961
export const COLOR: string;
@@ -122,6 +124,7 @@ declare module '$env/static/private' {
122124
export const NVM_RC_VERSION: string;
123125
export const INIT_CWD: string;
124126
export const EDITOR: string;
127+
export const NODE_ENV: string;
125128
}
126129

127130
/**
@@ -164,6 +167,7 @@ declare module '$env/dynamic/private' {
164167
npm_config_noproxy: string;
165168
HOME: string;
166169
CHROME_DESKTOP: string;
170+
OLDPWD: string;
167171
TERM_PROGRAM_VERSION: string;
168172
DESKTOP_SESSION: string;
169173
npm_package_json: string;
@@ -179,6 +183,7 @@ declare module '$env/dynamic/private' {
179183
HOMEBREW_SHELLENV_PREFIX: string;
180184
SYSTEMD_EXEC_PID: string;
181185
DBUS_SESSION_BUS_ADDRESS: string;
186+
npm_config_engine_strict: string;
182187
COLORTERM: string;
183188
GIO_LAUNCHED_DESKTOP_FILE_PID: string;
184189
COLOR: string;
@@ -247,6 +252,8 @@ declare module '$env/dynamic/private' {
247252
NVM_RC_VERSION: string;
248253
INIT_CWD: string;
249254
EDITOR: string;
255+
NODE_ENV: string;
256+
[key: `PUBLIC_${string}`]: undefined;
250257
[key: string]: string | undefined;
251258
}
252259
}
@@ -263,6 +270,6 @@ declare module '$env/dynamic/private' {
263270
*/
264271
declare module '$env/dynamic/public' {
265272
export const env: {
266-
[key: string]: string | undefined;
273+
[key: `PUBLIC_${string}`]: string | undefined;
267274
}
268275
}

.svelte-kit/generated/client-manifest.js

Lines changed: 13 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,19 +9,22 @@ export const nodes = [() => import('./nodes/0'),
99
() => import('./nodes/6'),
1010
() => import('./nodes/7'),
1111
() => import('./nodes/8'),
12-
() => import('./nodes/9')];
12+
() => import('./nodes/9'),
13+
() => import('./nodes/10'),
14+
() => import('./nodes/11')];
1315

14-
export const server_loads = [];
16+
export const server_loads = [2];
1517

1618
export const dictionary = {
17-
"/": [2],
18-
"/about": [3],
19-
"/api": [4],
20-
"/blog": [5],
21-
"/examples": [6],
22-
"/faq": [7],
23-
"/guide": [8],
24-
"/tutorial": [9]
19+
"/": [3],
20+
"/about": [4],
21+
"/api": [5],
22+
"/blog": [6],
23+
"/docs": [7,[2]],
24+
"/docs/[...docsPage]": [8,[2]],
25+
"/examples": [9],
26+
"/faq": [10],
27+
"/tutorial": [11]
2528
};
2629

2730
export const hooks = {

.svelte-kit/generated/nodes/2.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
1-
import * as shared from "../../../src/routes/+page.ts";
2-
export { shared };
3-
export { default as component } from "../../../src/routes/+page.svelte";
1+
export { default as component } from "../../../src/routes/docs/+layout.svelte";
2+
export const server = true;

.svelte-kit/generated/nodes/3.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
1-
export { default as component } from "../../../src/routes/about/+page.svelte";
1+
import * as universal from "../../../src/routes/+page.ts";
2+
export { universal };
3+
export { default as component } from "../../../src/routes/+page.svelte";

.svelte-kit/generated/nodes/4.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export { default as component } from "../../../src/routes/api/+page.svelte";
1+
export { default as component } from "../../../src/routes/about/+page.svelte";

.svelte-kit/generated/nodes/5.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export { default as component } from "../../../src/routes/blog/+page.svelte";
1+
export { default as component } from "../../../src/routes/api/+page.svelte";

.svelte-kit/generated/nodes/6.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export { default as component } from "../../../src/routes/examples/+page.svelte";
1+
export { default as component } from "../../../src/routes/blog/+page.svelte";

.svelte-kit/generated/nodes/7.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export { default as component } from "../../../src/routes/faq/+page.svelte";
1+
export { default as component } from "../../../src/routes/docs/+page.svelte";

.svelte-kit/generated/nodes/8.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
1-
export { default as component } from "../../../src/routes/guide/+page.svelte";
1+
import * as universal from "../../../src/routes/docs/[...docsPage]/+page.ts";
2+
export { universal };
3+
export { default as component } from "../../../src/routes/docs/[...docsPage]/+page.svelte";

.svelte-kit/generated/nodes/9.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export { default as component } from "../../../src/routes/tutorial/+page.svelte";
1+
export { default as component } from "../../../src/routes/examples/+page.svelte";

.svelte-kit/generated/root.svelte

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
export let form;
1212
export let data_0 = null;
1313
export let data_1 = null;
14+
export let data_2 = null;
1415
1516
if (!browser) {
1617
setContext('__svelte__', stores);
@@ -38,7 +39,13 @@
3839

3940
{#if components[1]}
4041
<svelte:component this={components[0]} data={data_0}>
41-
<svelte:component this={components[1]} data={data_1} {form} />
42+
{#if components[2]}
43+
<svelte:component this={components[1]} data={data_1}>
44+
<svelte:component this={components[2]} data={data_2} {form} />
45+
</svelte:component>
46+
{:else}
47+
<svelte:component this={components[1]} data={data_1} {form} />
48+
{/if}
4249
</svelte:component>
4350
{:else}
4451
<svelte:component this={components[0]} data={data_0} {form} />

.svelte-kit/types/route_meta_data.json

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,18 @@
22
"/": [
33
"src/routes/+page.ts"
44
],
5-
"/tutorial": [],
6-
"/docs": [],
7-
"/examples": [],
5+
"/about": [],
6+
"/api": [],
87
"/blog": [],
8+
"/docs": [
9+
"src/routes/docs/+layout.server.ts",
10+
"src/routes/docs/+layout.server.ts"
11+
],
12+
"/docs/[...docsPage]": [
13+
"src/routes/docs/[...docsPage]/+page.ts",
14+
"src/routes/docs/+layout.server.ts"
15+
],
16+
"/examples": [],
917
"/faq": [],
10-
"/about": [],
11-
"/guide": [],
12-
"/api": []
18+
"/tutorial": []
1319
}

.svelte-kit/types/src/routes/$types.d.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ type OutputDataShape<T> = MaybeWithVoid<Omit<App.PageData, RequiredKeys<T>> & Pa
99
type EnsureDefined<T> = T extends null | undefined ? {} : T;
1010
type OptionalUnion<U extends Record<string, any>, A extends keyof U = U extends U ? keyof U : never> = U extends unknown ? { [P in Exclude<A, keyof U>]?: never } & U : never;
1111
type PageParentData = EnsureDefined<LayoutData>;
12-
type LayoutRouteId = RouteId | "/" | "/about" | "/api" | "/blog" | "/examples" | "/faq" | "/guide" | "/tutorial" | null
13-
type LayoutParams = RouteParams & { }
12+
type LayoutRouteId = RouteId | "/" | "/about" | "/api" | "/blog" | "/docs" | "/docs/[...docsPage]" | "/examples" | "/faq" | "/tutorial" | null
13+
type LayoutParams = RouteParams & { docsPage?: string }
1414
type LayoutParentData = EnsureDefined<{}>;
1515

1616
export type PageServerData = null;

.svelte-kit/types/src/routes/docs/$types.d.ts

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,16 @@ export type RequiredKeys<T> = { [K in keyof T]-?: {} extends { [P in K]: T[K] }
88
type OutputDataShape<T> = MaybeWithVoid<Omit<App.PageData, RequiredKeys<T>> & Partial<Pick<App.PageData, keyof T & keyof App.PageData>> & Record<string, any>>
99
type EnsureDefined<T> = T extends null | undefined ? {} : T;
1010
type OptionalUnion<U extends Record<string, any>, A extends keyof U = U extends U ? keyof U : never> = U extends unknown ? { [P in Exclude<A, keyof U>]?: never } & U : never;
11-
type PageParentData = EnsureDefined<import('../$types.js').LayoutData>;
11+
type PageParentData = Omit<EnsureDefined<import('../$types.js').LayoutData>, keyof LayoutData> & EnsureDefined<LayoutData>;
12+
type LayoutRouteId = RouteId | "/docs" | "/docs/[...docsPage]"
13+
type LayoutParams = RouteParams & { docsPage?: string }
14+
type LayoutServerParentData = EnsureDefined<import('../$types.js').LayoutServerData>;
15+
type LayoutParentData = EnsureDefined<import('../$types.js').LayoutData>;
1216

1317
export type PageServerData = null;
14-
export type PageData = Expand<PageParentData>;
18+
export type PageData = Expand<PageParentData>;
19+
export type LayoutServerLoad<OutputData extends OutputDataShape<LayoutServerParentData> = OutputDataShape<LayoutServerParentData>> = Kit.ServerLoad<LayoutParams, LayoutServerParentData, OutputData, LayoutRouteId>;
20+
export type LayoutServerLoadEvent = Parameters<LayoutServerLoad>[0];
21+
export type LayoutServerData = Expand<OptionalUnion<EnsureDefined<Kit.AwaitedProperties<Awaited<ReturnType<typeof import('../../../../../src/routes/docs/+layout.server.js').load>>>>>>;
22+
export type LayoutData = Expand<Omit<LayoutParentData, keyof LayoutServerData> & EnsureDefined<LayoutServerData>>;
23+
export type RequestEvent = Kit.RequestEvent<RouteParams, RouteId>;

.svelte-kit/types/src/routes/guide/$types.d.ts

Lines changed: 0 additions & 14 deletions
This file was deleted.

0 commit comments

Comments
 (0)