aklinker1 / vite-plugin-web-extension

Vite plugin for developing Chrome/Web Extensions
https://vite-plugin-web-extension.aklinker1.io/
MIT License
574 stars 48 forks source link

feat: add a `skipAutoLaunch` option #12

Closed KentoNishi closed 2 years ago

KentoNishi commented 2 years ago

The auto-launching behavior can be undesirable in many circumstances like:

I've added a skipAutoInstall option to easily disable auto-installing and launching to deal with that :)

KentoNishi commented 2 years ago

For edge, you should be able to point web-ext's chromiumBinary to edge's path, and it should auto-install just fine if that's the problem

Yeah that would work I think, but I often have an inspected extension page open before starting the dev server, and it bugs me that the tab gets closed when the extension reloads. I prefer reloading manually when I want to, but that's just my preference lol

For WSL, I know there are limitations when interacting with windows programs (I've had problems with electron in the past), but what's the limitation here?

When the package is being loaded, it must be loaded from \\wsl$\tmp rather than /tmp because the /tmp path doesn't exist on the c drive. WSL2's inter-OS operations are also very very slow, so I'd rather avoid driving chromium from WSL entirely.

I'll get to work on the small fixes now :D

KentoNishi commented 2 years ago

@aklinker1 By the way, I just wanted to say thank you for making such a great plugin. I'm kinda shocked how much effort you've put into a niche project like this, hopefully it becomes popular as vite gains more traction 🚀

aklinker1 commented 2 years ago

@KentoNishi Thanks! Bundling a web extension from scratch is difficult to configure, so I decided to publish my build process I made for one of my personal extensions.

This has been published in v1.1.0 BTW