Skip to content

Commit f5fcf7c

Browse files
Support Windows deep links
1 parent 888c3f6 commit f5fcf7c

File tree

5 files changed

+13
-1
lines changed

5 files changed

+13
-1
lines changed

.env-example

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,4 @@ PUBLIC_ANDROID_CERTS_SHA256=sha256
1010
PUBLIC_APPLE_STORE_URL=https://apple-url.example.org
1111
PUBLIC_APPLE_APP_ID=apple-id
1212
PUBLIC_WINDOWS_STORE_URL=https://windows-url.example.org
13+
PUBLIC_WINDOWS_APP_FAMILY_NAME=windows-family-name

src/routes/.well-known/apple-app-site-association/+server.ts renamed to src/routes/(deep-links)/.well-known/apple-app-site-association/+server.ts

File renamed without changes.

src/routes/.well-known/assetlinks.json/+server.ts renamed to src/routes/(deep-links)/.well-known/assetlinks.json/+server.ts

File renamed without changes.
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import { json, type RequestHandler } from '@sveltejs/kit';
2+
import { env } from '$env/dynamic/public';
3+
4+
export const GET = (() =>
5+
json([
6+
{
7+
packageFamilyName: env.PUBLIC_WINDOWS_APP_FAMILY_NAME,
8+
paths: ['*'],
9+
excludePaths: []
10+
}
11+
])) satisfies RequestHandler;

svelte.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ const config = {
1111
typescript: {
1212
config(config) {
1313
// The default globs in .svelte-kit/tsconfig.json ignore paths starting with a dot
14-
config.include.push('../src/routes/.well-known/**/*.ts');
14+
config.include.push('../src/routes/(deep-links)/.well-known/**/*.ts');
1515
config.include.push('../src/lib/api/*.ts');
1616
return config;
1717
}

0 commit comments

Comments
 (0)