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

Vite Plugin for Svelte Support #3503

Closed
3 tasks done
Sahasrara opened this issue Feb 23, 2024 · 2 comments
Closed
3 tasks done

Vite Plugin for Svelte Support #3503

Sahasrara opened this issue Feb 23, 2024 · 2 comments

Comments

@Sahasrara
Copy link

Pre-flight checklist

  • I have read the contribution documentation for this project.
  • I agree to follow the code of conduct that this project uses.
  • I have searched the issue tracker for a feature request that matches the one I want to file, without success.

Problem description

It's not currently possible to build a svelte app using Vite with Electron Forge. It'd be super cool if that was possible. Forge doesn't work with @sveltejs/vite-plugin-svelte.

Proposed solution

I'm not sure what would be required, but I'd like to be able to use Svelte + Vite + Electron + Forge. Right now, you can't import @sveltejs/vite-plugin-svelte because it's an ESM only module.

Alternatives considered

I'm currently using electron-vite, but I'd feel safer working with a Forge since it has a larger community backing it.

Additional information

No response

@caoxiemeihao
Copy link
Member

caoxiemeihao commented Apr 19, 2024

I provide a Forge + Vite + Svelte sample here. 👉 https://github.com/caoxiemeihao/electron-vite-samples/tree/main/forge-svelte

screenshot

BTW, Perhaps the next version of @forge/template-vite will support ESM fully, I'm currently testing the feasibility of ESM in electron-vite-vue.

@caoxiemeihao
Copy link
Member

I've provided samples for esm.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants