Skip to content

Commit

Permalink
fix(netlify): don't try to render .netlify/*
Browse files Browse the repository at this point in the history
Fixes #5235.
  • Loading branch information
serhalp committed Mar 28, 2024
1 parent aed3284 commit 5c3e74a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/witty-teachers-film.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@sveltejs/adapter-netlify": patch
---

Fix conflict between Netlify Edge Functions and Netlify Identity. Avoid unnecessary Netlify edge function invocations for static files.
4 changes: 3 additions & 1 deletion packages/adapter-netlify/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,9 @@ async function generate_edge_functions({ builder }) {
const path = '/*';
const excludedPath = [
// Contains static files
`/${builder.getAppPath()}/*`
`/${builder.getAppPath()}/*`,
// Should not be served by SvelteKit at all
'/.netlify/*'
];

/** @type {HandlerManifest} */
Expand Down

0 comments on commit 5c3e74a

Please sign in to comment.