alex8088 / quick-start

An easy way to start a front-end project.
MIT License
264 stars 37 forks source link

Error: Electron uninstall #9

Closed Susiia closed 1 year ago

Susiia commented 1 year ago

Describe the bug

pnpm create @quick-start/electron

pnpm run dev

dev server running for the electron renderer process at: ➜ Local: http://127.0.0.1:5173/ ➜ Network: use --host to expose error during start dev server and electron app: Error: Electron uninstall at getElectronPath (D:\MyFile\Working-Company\Project\stepOnAMine\node_modules.pnpm\electron-vite@1.0.18_vite@4.0.4\node_modules\electron-vite\dist\chunks\lib-ddb42891.js:68:19) at Object.startElectron (D:\MyFile\Working-Company\Project\stepOnAMine\node_modules.pnpm\electron-vite@1.0.18_vite@4.0.4\node_modules\electron-vite\dist\chunks\lib-ddb42891.js:123:26) at createServer (D:\MyFile\Working-Company\Project\stepOnAMine\node_modules.pnpm\electron-vite@1.0.18_vite@4.0.4\node_modules\electron-vite\dist\chunks\lib-b694cd80.js:75:21) at async CAC. (D:\MyFile\Working-Company\Project\stepOnAMine\node_modules.pnpm\electron-vite@1.0.18_vite@4.0.4\node_modules\electron-vite\dist\cli.js:47:9)  ELIFECYCLE  Command failed with exit code 1. ----------------------------------------------# my package.json#------------------------------- { "name": "steponamine", "version": "1.0.0", "description": "An Electron application with Vue and TypeScript", "main": "./out/main/index.js", "author": "example.com", "homepage": "https://www.electronjs.org", "scripts": { "format": "prettier --write .", "lint": "eslint . --ext .js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts,.vue --fix", "typecheck:node": "tsc --noEmit -p tsconfig.node.json --composite false", "typecheck:web": "vue-tsc --noEmit -p tsconfig.web.json --composite false", "typecheck": "npm run typecheck:node && npm run typecheck:web", "start": "electron-vite preview", "dev": "electron-vite dev", "build": "npm run typecheck && electron-vite build", "postinstall": "electron-builder install-app-deps", "build:win": "npm run build && electron-builder --win --config", "build:mac": "npm run build && electron-builder --mac --config", "build:linux": "npm run build && electron-builder --linux --config" }, "dependencies": { "@electron-toolkit/preload": "^1.0.3", "@electron-toolkit/utils": "^1.0.2" }, "devDependencies": { "@electron-toolkit/tsconfig": "^1.0.1", "@electron/notarize": "^1.2.3", "@rushstack/eslint-patch": "^1.2.0", "@types/node": "16.18.11", "@vitejs/plugin-vue": "^4.0.0", "@vue/eslint-config-prettier": "^7.0.0", "@vue/eslint-config-typescript": "^11.0.2", "electron": "^21.3.3", "electron-builder": "^23.6.0", "electron-vite": "^1.0.17", "eslint": "^8.31.0", "eslint-plugin-vue": "^9.8.0", "less": "^4.1.3", "prettier": "^2.8.2", "typescript": "^4.9.4", "vite": "^4.0.4", "vue": "^3.2.45", "vue-tsc": "^1.0.22" } }

Used Scaffolding

create-electron

Used Package Manager

pnpm

Validations

alex8088 commented 1 year ago

Electron post install problem with pnpm. You can rm node_modules and run pnpm store prune to clear store cache.