Git Product home page Git Product logo

phonegap-template-react-hot-loader's Introduction

Vue Hot Reloading Template For Cordova / PhoneGap

Vue,Vuex,Vue-Router Cordova / PhoneGap Template with Babel, Webpack and Hot Reloading

Getting Started

Prerequisites

To use this template, you'll need Node.js v5 or newer.

Installation

To use this as a template, use Cordova 6.0.0+ and create a new project:

cordova create MyAppName --template=https://github.com/yunshansimon/phonegap-template-react-hot-loader
cd MyAppName
npm install

Write your ES6 code

|-index.html
|--src
|   |--main.js      # bootstrap file  
|   |--App.vue      # main Vue file
|   |--components   # vue components directory
|   |--vuex         # vuex file
|--res              # cordova icons and flash screen images
|--build            # npm build/prepare js commands
|--www              # cordova source directory
|--hooks            # cordova hooks directory (Deprecated)
|--static           # keep for old commands

Run the app in the browser / simulator

Run this to start the development webpack server:

npm run dev

You can then open the app in your browser by visiting localhost:8080

Notice:You need install Cordova, Node.js on your system.

Build the app for production

Compile your ES6 code to Cordova /www directory and copy the files to Cordova platform directory

npm run prepare

Use cordova to build your app:

cordova buile android --[debug,release]

This will switch your config.xml file to production mode, build the app bundle to /www using Webpack, and run cordova build for you.

After that, the normal Cordova / PhoneGap commands can be used such as phonegap serve, or cordova run ios, etc.

License

MIT. Copyright (c) 2016 Jed Watson. Yang Tsao.

phonegap-template-react-hot-loader's People

Contributors

devgeeks avatar jedwatson avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.