Difference between revisions of "User:Saul/electron"

From Organic Design wiki
m (Create Vue Project)
(Electron CLI)
Line 9: Line 9:
 
<source lang="bash">
 
<source lang="bash">
 
sudo npm i -g electron --unsafe-perm=true --allow-root
 
sudo npm i -g electron --unsafe-perm=true --allow-root
 +
</source>
 +
== Electron Forge CLI ==
 +
I recomend using electron forge.
 +
<source lang="bash">
 +
sudo npm install -g electron-forge # install electron-forge globally.
 +
</source>
 +
Again if it errors you can force with
 +
<source lang="bash">
 +
sudo npm install -g electron-forge --unsafe-perm=true --allow-root # install electron-forge globally.
 
</source>
 
</source>
  

Revision as of 22:47, 11 July 2018

This page is for my notes on using electron with vue.

Install

Electron CLI

sudo npm i -g electron # install electron globally.

If you get an error about not being able to create a folder, you can force it with

sudo npm i -g electron --unsafe-perm=true --allow-root

Electron Forge CLI

I recomend using electron forge.

sudo npm install -g electron-forge # install electron-forge globally.

Again if it errors you can force with

sudo npm install -g electron-forge --unsafe-perm=true --allow-root # install electron-forge globally.

Create Vue Project

mkdir <PROJECT NAME> && cd <PROJECT NAME>
vue init webpack <PROJECT NAME> # create the project using the vue's cli.
npm i electron
npm i