Security News
JSR Working Group Kicks Off with Ambitious Roadmap and Plans for Open Governance
At its inaugural meeting, the JSR Working Group outlined plans for an open governance model and a roadmap to enhance JavaScript package management.
vite-plugin-electron-x
Advanced tools
A Vite plugin for bundling `main.ts`, `preload.ts` and running Electron in development.
A Vite plugin for bundling main.ts
, preload.ts
and running Electron in development.
Add the plugin in vite.config.js
like this:
export default defineConfig({
plugins: [
electronX({
main: {
// this will output ./build/electron/main.js
entry: './src/electron/main.ts',
outDir: './build/electron',
},
preload: {
// this will output ./build/electro/preload.js
entry: './src/electron/preload.ts',
outDir: './build/electron',
},
}),
]
})
You can load the dev server in Electron using process.env.VITE_DEV_SERVER_URL
:
if (process.env.VITE_DEV_SERVER_URL) {
win.loadURL(`http://localhost:${process.env.VITE_DEV_SERVER_URL}`)
} else {
// win.loadURL('your-production-output.html')
}
Docs: https://paka.dev/npm/vite-plugin-electron-x
npm install
npm run dev
: Build and watchnpm run build
: Buildnpm run format
: FormatCHANGELOG.md
npm run lint
npm version --no-git-tag <version>
npm run build
npm publish
1.2.2 - 2023 Feb 21
FAQs
A Vite plugin for bundling `main.ts`, `preload.ts` and running Electron in development.
The npm package vite-plugin-electron-x receives a total of 0 weekly downloads. As such, vite-plugin-electron-x popularity was classified as not popular.
We found that vite-plugin-electron-x demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
At its inaugural meeting, the JSR Working Group outlined plans for an open governance model and a roadmap to enhance JavaScript package management.
Security News
Research
An advanced npm supply chain attack is leveraging Ethereum smart contracts for decentralized, persistent malware control, evading traditional defenses.
Security News
Research
Attackers are impersonating Sindre Sorhus on npm with a fake 'chalk-node' package containing a malicious backdoor to compromise developers' projects.