Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixes #2 fixes #3 update code sample to work with Ionic v2 beta 3 #4

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion app/app.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
import {App, IonicApp, Platform} from 'ionic-framework/ionic';
import 'zone.js';
import 'reflect-metadata';
import 'es6-shim';
import {App, IonicApp, Platform} from 'ionic-angular';
import {WelcomePage} from './pages/welcome/welcome';
import {PropertyListPage} from './pages/property-list/property-list';
import {BrokerListPage} from './pages/broker-list/broker-list';
Expand Down
2 changes: 1 addition & 1 deletion app/pages/broker-details/broker-details.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import {OnInit} from 'angular2/core';
import {Page, NavController, NavParams} from 'ionic-framework/ionic';
import {Page, NavController, NavParams} from 'ionic-angular';
import {BrokerService} from '../../services/broker-service';

@Page({
Expand Down
2 changes: 1 addition & 1 deletion app/pages/broker-list/broker-list.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import {OnInit} from 'angular2/core';
import {Page, NavController, NavParams} from 'ionic-framework/ionic';
import {Page, NavController, NavParams} from 'ionic-angular';
import {BrokerDetailsPage} from '../broker-details/broker-details';
import {BrokerService} from '../../services/broker-service';

Expand Down
2 changes: 1 addition & 1 deletion app/pages/favorite-list/favorite-list.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import {OnInit} from 'angular2/core';
import {Page, NavController, NavParams} from 'ionic-framework/ionic';
import {Page, NavController, NavParams} from 'ionic-angular';
import {PropertyDetailsPage} from '../property-details/property-details';
import {PropertyService} from '../../services/property-service';

Expand Down
2 changes: 1 addition & 1 deletion app/pages/property-details/property-details.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Page, NavController, NavParams, Alert, ActionSheet} from 'ionic-framework/ionic';
import {Page, NavController, NavParams, Alert, ActionSheet} from 'ionic-angular';
import {BrokerDetailsPage} from '../broker-details/broker-details';
import {PropertyService} from '../../services/property-service';

Expand Down
2 changes: 1 addition & 1 deletion app/pages/property-list/property-list.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import {OnInit} from 'angular2/core';
import {Page, NavController, NavParams} from 'ionic-framework/ionic';
import {Page, NavController, NavParams} from 'ionic-angular';
import {PropertyDetailsPage} from '../property-details/property-details';
import {PropertyService} from '../../services/property-service';

Expand Down
2 changes: 1 addition & 1 deletion app/pages/welcome/welcome.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Page, NavController, NavParams} from 'ionic-framework/ionic';
import {Page, NavController, NavParams} from 'ionic-angular';

@Page({
templateUrl: 'build/pages/welcome/welcome.html'
Expand Down
22 changes: 14 additions & 8 deletions config.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,18 @@
<allow-intent href="itms:*" />
<allow-intent href="itms-apps:*" />
</platform>
<preference name="webviewbounce" value="false" />
<preference name="UIWebViewBounce" value="false" />
<preference name="DisallowOverscroll" value="true" />
<preference name="android-minSdkVersion" value="16" />
<preference name="BackupWebStorage" value="none" />
<feature name="StatusBar">
<param name="ios-package" onload="true" value="CDVStatusBar" />
</feature>
<preference name="webviewbounce" value="false"/>
<preference name="UIWebViewBounce" value="false"/>
<preference name="DisallowOverscroll" value="true"/>
<preference name="android-minSdkVersion" value="16"/>
<preference name="BackupWebStorage" value="none"/>
<feature name="StatusBar">
<param name="ios-package" onload="true" value="CDVStatusBar"/>
</feature>
<plugin name="cordova-plugin-device" spec="~1.1.1"/>
<plugin name="cordova-plugin-console" spec="~1.0.2"/>
<plugin name="cordova-plugin-whitelist" spec="~1.2.1"/>
<plugin name="cordova-plugin-splashscreen" spec="~3.2.1"/>
<plugin name="cordova-plugin-statusbar" spec="~2.1.2"/>
<plugin name="ionic-plugin-keyboard" spec="~2.0.1"/>
</widget>
48 changes: 48 additions & 0 deletions gulpfile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
var gulp = require('gulp'),
gulpWatch = require('gulp-watch'),
del = require('del'),
argv = process.argv;


/**
* Ionic hooks
* Add ':before' or ':after' to any Ionic project command name to run the specified
* tasks before or after the command.
*/
gulp.task('serve:before', ['watch']);
gulp.task('emulate:before', ['build']);
gulp.task('deploy:before', ['build']);
gulp.task('build:before', ['build']);

// we want to 'watch' when livereloading
var shouldWatch = argv.indexOf('-l') > -1 || argv.indexOf('--livereload') > -1;
gulp.task('run:before', [shouldWatch ? 'watch' : 'build']);

/**
* Ionic Gulp tasks, for more information on each see
* https://github.com/driftyco/ionic-gulp-tasks
*
* Using these will allow you to stay up to date if the default Ionic 2 build
* changes, but you are of course welcome (and encouraged) to customize your
* build however you see fit.
*/
var buildBrowserify = require('ionic-gulp-browserify-es2015');
var buildSass = require('ionic-gulp-sass-build');
var copyHTML = require('ionic-gulp-html-copy');
var copyFonts = require('ionic-gulp-fonts-copy');
var copyScripts = require('ionic-gulp-scripts-copy');

gulp.task('watch', ['sass', 'html', 'fonts', 'scripts'], function(){
gulpWatch('app/**/*.scss', function(){ gulp.start('sass'); });
gulpWatch('app/**/*.html', function(){ gulp.start('html'); });
return buildBrowserify({ watch: true });
});

gulp.task('build', ['sass', 'html', 'fonts', 'scripts'], buildBrowserify);
gulp.task('sass', buildSass);
gulp.task('html', copyHTML);
gulp.task('fonts', copyFonts);
gulp.task('scripts', copyScripts);
gulp.task('clean', function(done){
del('www/build', done);
});
54 changes: 0 additions & 54 deletions ionic.config.js

This file was deleted.

3 changes: 2 additions & 1 deletion ionic.project → ionic.config.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{
"name": "ionic2-realty",
"app_id": ""
"app_id": "",
"v2": true
}
33 changes: 25 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,36 @@
"angular2": "2.0.0-beta.6",
"es6-promise": "3.0.2",
"es6-shim": "0.33.13",
"ionic-framework": "2.0.0-beta.1",
"ionic-angular": "2.0.0-beta.3",
"ionic-native": "^1.1.0",
"ionicons": "3.0.0-alpha.3",
"reflect-metadata": "0.1.2",
"rxjs": "5.0.0-beta.0",
"zone.js": "0.5.14"
},
"devDependencies": {
"babel-core": "6.5.2",
"babel-loader": "6.2.3",
"babel-plugin-transform-decorators-legacy": "1.3.4",
"babel-preset-es2015": "6.5.0",
"strip-sourcemap-loader": "0.0.1"
"babel-preset-es2015": "6.6.0",
"babelify": "7.2.0",
"del": "2.2.0",
"gulp": "3.9.1",
"gulp-watch": "4.3.5",
"ionic-gulp-browserify-es2015": "^1.0.0",
"ionic-gulp-fonts-copy": "^1.0.0",
"ionic-gulp-html-copy": "^1.0.0",
"ionic-gulp-sass-build": "^1.0.0",
"ionic-gulp-scripts-copy": "^1.0.0"
},
"name": "tmp",
"description": "tmp: An Ionic project"
}
"name": "ionic-2-realty",
"description": "Ionic2 Realty: An Ionic project",
"version": "0.3.0",
"cordovaPlugins": [
"cordova-plugin-device",
"cordova-plugin-console",
"cordova-plugin-whitelist",
"cordova-plugin-splashscreen",
"cordova-plugin-statusbar",
"ionic-plugin-keyboard"
],
"cordovaPlatforms": []
}
47 changes: 0 additions & 47 deletions webpack.config.js

This file was deleted.