Skip to content

Commit

Permalink
Merge branch 'vercel' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
Yureien committed Oct 8, 2023
2 parents 994652a + ead7758 commit 1984991
Show file tree
Hide file tree
Showing 4 changed files with 471 additions and 11 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,4 @@ node_modules
!.env.example
vite.config.js.timestamp-*
vite.config.ts.timestamp-*
.vercel
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
"devDependencies": {
"@sveltejs/adapter-auto": "^2.0.0",
"@sveltejs/adapter-node": "^1.2.4",
"@sveltejs/adapter-vercel": "^3.0.3",
"@sveltejs/kit": "^1.5.0",
"@types/node-cron": "^3.0.7",
"@types/nodemailer": "^6.4.11",
Expand Down
11 changes: 9 additions & 2 deletions svelte.config.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
import adapter from '@sveltejs/adapter-node';
import adapter from '@sveltejs/adapter-vercel';
import { vitePreprocess } from '@sveltejs/kit/vite';

/** @type {import('@sveltejs/adapter-vercel').Config} */
export const adapterConfig = {
runtime: 'nodejs18.x',
regions: ['sin1'],
memory: 512
};

/** @type {import('@sveltejs/kit').Config} */
const config = {
// Consult https://kit.svelte.dev/docs/integrations#preprocessors
Expand All @@ -11,7 +18,7 @@ const config = {
// adapter-auto only supports some environments, see https://kit.svelte.dev/docs/adapter-auto for a list.
// If your environment is not supported or you settled on a specific environment, switch out the adapter.
// See https://kit.svelte.dev/docs/adapters for more information about adapters.
adapter: adapter(),
adapter: adapter(adapterConfig),
alias: {
'@db': './src/lib/server/prisma/prisma.ts'
}
Expand Down
Loading

0 comments on commit 1984991

Please sign in to comment.