/Vue-electron-template

Init a reposity

Primary LanguageJavaScript

Vue-electron-template

Got tired finding Electron/Vue2/Webpack2/Element templates with fancy add-ons you don't really need?

Give a try to this minimal template with very few dependencies for quick development and prototyping.

Install

# Clone the repository once
$ https://github.com/shengxihu/Vue-electron-template/

# Go into the repository (rename it as you wish)
$ cd Vue-electron-template

# Install the 7 only dependencies once
$ npm install

Usage

Run this two commands in two different prompts to start developing with hot reloading.

# Webpack builds once and watches to apply only the changes
$ npm run dev

# Start you electron app
$ npm start

What's included

You don't really need more stuff to start playing around with Electron, Vue 2 and Webpack 2.

  • Support for .vue (single file components). Use them with HTML & ES6 & CSS.
  • No Express, neither Babel is needed (more than 97% ES6 is supported in Node/Electron).

Template structure

├── Vue-electron-template/               # Your project's name
    ├── app/
        ├── build/                      # Webpack will bundle your css/js/img here
        ├── src/
            ├── assets/                 # assets go here   
            ├── components/             # Webcomponents go here
            ├── App.vue                 # Vue app. Your global css can go here
            ├── entry.js                # App entry. Your global js can go here
        ├── index.html                  # Single Page Application HTML, it only uses build's files
    ├── main.js                         # Electron app init
    ├── package.json
    ├── webpack.config.js               # Minimal webpack setup

reference && link

electron-vue-webpack