https://github.com/bluefrog130/file-upload-bug
https://github.com/bluefrog130/file-upload-bug
Last synced: 12 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/bluefrog130/file-upload-bug
- Owner: BlueFrog130
- Created: 2022-05-05T16:53:05.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2022-05-05T17:07:23.000Z (about 4 years ago)
- Last Synced: 2025-03-14T00:31:59.634Z (about 1 year ago)
- Language: Svelte
- Size: 1020 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# File upload bug
https://github.com/sveltejs/kit/issues/4832
This repo is to demonstrate a bug that occurs when dynamically adding files to the `static` folder when using `@sveltejs/adapter-node`.
## Reproduction
Clone this repo and build it.
```bash
npm run build
```
Next, navigate to the `build` directory and run the `index.js`
```bash
cd build && node index.js
```
Notice how after uploading files and clicking the links, a `404` is received, _even though_ the file is within the `static` folder.




## Notes
This seems to _only_ be an issue when running in production. Running in development works just fine
```bash
npm run dev # or preview <-- Works just fine
```