-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Start from version 1.0.0-next.337
to current 1.0.0-next.343
, use [...path].svelte
will overwrite assets import urls
#5066
Comments
5 tasks
workaround to have both assets url and 404 page is change |
Rich-Harris
added a commit
that referenced
this issue
Jul 5, 2022
Rich-Harris
added a commit
that referenced
this issue
Jul 6, 2022
Rich-Harris
added a commit
that referenced
this issue
Jul 8, 2022
* failing test for #5066 * allow vite to serve files where appropriate * print helpful 403 in dev * Update packages/kit/src/vite/dev/index.js * try and figure out why windows is failing * try this * store protocol and verbose instead of vite_config * neaten up * account for server.fs.strict * Update packages/kit/test/apps/basics/test/test.js Co-authored-by: Ben McCann <322311+benmccann@users.noreply.github.com> * Create nice-boxes-exercise.md Co-authored-by: Ben McCann <322311+benmccann@users.noreply.github.com>
closed via #5070 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the bug
start from version
1.0.0-next.337
to current1.0.0-next.343
. when define a route file to catch error 404 (file named[...path].svelte
) , it will catch asset urls imported in source too. This issue not happend until ver1.0.0-next.336
.Change log 337
i guess that the change in v*.337 regards to
Only run viteServeStaticMiddleware after server has attempted response (https://github.com/sveltejs/kit/pull/4974)
will be cause. But dont know how to help fix.Reproduction
npm init svelte <folder project name>
/src/lib/assets/a.jpg
/src/routes/index.svelte
import image to<script>
block, then create<img>
tag in template./src/routes
create new file name[...path].svelte
, define some html like a 404 catcher page.npm run dev
. see image url in chrome devtool will redirect to[...path].svelte
page .[...path].svelte
to[path].svelte
. run dev serer again, see img show correctly.[...path].svelte again, then run build
npm run buildand then
npm run preview`, the built version work ok so issue only happend with dev mode.Logs
No response
System Info
Severity
blocking an upgrade
The text was updated successfully, but these errors were encountered: