Skip to content
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

Polyfills() error when running in production #23

Closed
peterlerche opened this issue Aug 26, 2023 · 1 comment
Closed

Polyfills() error when running in production #23

peterlerche opened this issue Aug 26, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@peterlerche
Copy link

Using a skeleton bun project following the guideline https://bun.sh/guides/ecosystem/sveltekit and replacing @sveltejs/adapter-auto with svelte-adapter-bun, I get the following error when running.

bun --bun run ./build/index.js 
572 | }, globals = {
573 |   File
574 | };
575 | function installPolyfills() {
576 |   for (let name in globals)
577 |     Object.defineProperty(globalThis, name, {
        ^
TypeError: Attempting to change configurable attribute of unconfigurable property.
      at installPolyfills (/home/peterl/Code/my-app/build/index.js:577:4)
      at /home/peterl/Code/my-app/build/index.js:587:0

Executing dev, build, and preview work flawlessly.

Is the polyfill for the File class legacy code?

@gornostay25
Copy link
Owner

Thanks for your issue. Yeah, now Bun support File it will be fixed in new version of adapter
Thanks @kolchurinvv #22

@gornostay25 gornostay25 added the bug Something isn't working label Aug 27, 2023
gornostay25 pushed a commit that referenced this issue Aug 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants