Starskeeper's development is coming to an end, trying to pack it up, but Fullscreen's error is recorded to prevent another step in the pit
First, the project Scaffold is Electron-vue project, when the project scaffolding will be generated when you choose the Packaging method (Electron-packager OR electron-builder), I chose the former
View the project's Package.json file, find the command that was packaged on the MacOS platform npm build build:darwin
, and then error. Error message can not, anyway, because I install dependent on the time with the CNPM, change to NPM is OK , the specific reason is unknown. Then you can package it into an. app file
Then open the app, white screen. In the production environment is not open the Dev window, then you can add a similar open window in the code, mainWindow.openDevTools()
I found that I index.ejs
used to //xxx
introduce a CDN, and then because the open file is a local file, files protocol beginning, so the error, remove this useless CDN introduced Okay, OK.
Then the package is finished, 130m+, self-use can also accept
By the way, note the other errors that may be generated:
- Node version is too low (I'm v8.0.0 version, no problem)
- NPM version issue (@5.3.0 will have a problem, see issue, Upgrade NPM)
- White screen problem. This issue points out the scheme of configuring Whitelistedmodules, I have appeared as he pictured
[not cacheable]
, but the packing result is no problem. Also, this issue indicates that a piece of code can be commented to solve the problem
Electron-vue the problem of packing with Electron-packager