swennemans / react-cordova-reflux

React reflux starter, with optional cordova/phonegap option.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

React Reflux with cordova/phonegap

This React starterkit uses: gulp, stylus, webpack, react-hot-loader, babel for ES6 syntax and .jsx handling. Reflux is used for the dataflow and the routing is managed with the React-Router.

provides a prepared development environment based on gulp, stylus and webpack. The internal data flow is handled with Reflux and routing with React-Router.

Install

Install all dependencies.

$ npm install

Development

Normal (non-cordova)

Build and serve application

$ gulp run

Served from: http://localhost:3000/build/index.html#/

Cordova/phonegap

Create cordova/phonegap app

$ gulp cordova-create

Run cordova/phonegap server

Run cordova/phonegap on cordova server for testing your app in PhoneGap Developer App. Auto-reloads on change. Much slower (approx. 4 seconds) then in normal dev mode.

$ gulp run --type cordova

Check console log for adress.

Installing Cordova Plugins

Add plugin entries at

cordova.config.js

App

Javascript

Javascript entry file: app/scripts/main.js

CSS / Stylus

Uses Stylus-loader to import Stylus files from your .jsx files.

import './style.styl' //ES6 syntax
require('./style.styl)

##Credits Heavenly borrowed from:

About

React reflux starter, with optional cordova/phonegap option.


Languages

Language:JavaScript 91.6%Language:HTML 4.5%Language:CSS 3.9%