Skip to content

Commit

Permalink
Update to Ionic 3.2.1
Browse files Browse the repository at this point in the history
To update, delete node_modules folder, run npm install. New build and serve commands: npm run build, npm run serve
  • Loading branch information
scottopolis committed May 17, 2017
1 parent 00c2f2d commit 241133d
Show file tree
Hide file tree
Showing 5 changed files with 42 additions and 24 deletions.
38 changes: 20 additions & 18 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,29 +4,31 @@
"homepage": "http:https://ionicframework.com/",
"private": true,
"scripts": {
"ionic:build": "ionic-app-scripts build",
"ionic:serve": "ionic-app-scripts serve"
"build": "ionic-app-scripts build",
"serve": "ionic-app-scripts serve"
},
"dependencies": {
"@angular/common": "2.1.1",
"@angular/compiler": "2.1.1",
"@angular/compiler-cli": "2.1.1",
"@angular/core": "2.1.1",
"@angular/forms": "2.1.1",
"@angular/http": "2.1.1",
"@angular/platform-browser": "2.1.1",
"@angular/platform-browser-dynamic": "2.1.1",
"@angular/platform-server": "2.1.1",
"@ionic/storage": "1.1.6",
"ionic-angular": "2.0.0-rc.3",
"ionic-native": "2.2.3",
"@angular/common": "4.1.0",
"@angular/compiler": "4.1.0",
"@angular/compiler-cli": "4.1.0",
"@angular/core": "4.1.0",
"@angular/forms": "4.1.0",
"@angular/http": "4.1.0",
"@angular/platform-browser": "4.1.0",
"@angular/platform-browser-dynamic": "4.1.0",
"@ionic-native/core": "3.6.1",
"@ionic-native/splash-screen": "3.6.1",
"@ionic-native/status-bar": "3.6.1",
"@ionic/storage": "2.0.1",
"ionic-angular": "3.2.1",
"ionicons": "3.0.0",
"rxjs": "5.0.0-beta.12",
"zone.js": "0.6.26"
"rxjs": "5.1.1",
"sw-toolbox": "3.6.0",
"zone.js": "0.8.10"
},
"devDependencies": {
"@ionic/app-scripts": "0.0.45",
"typescript": "2.0.6"
"@ionic/app-scripts": "1.3.7",
"typescript": "2.2.1"
},
"cordovaPlugins": [
"cordova-plugin-whitelist",
Expand Down
9 changes: 5 additions & 4 deletions src/app/app.component.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { Component } from '@angular/core';
import { Platform } from 'ionic-angular';
import { StatusBar, Splashscreen } from 'ionic-native';
import { SplashScreen } from '@ionic-native/splash-screen';
import { StatusBar } from '@ionic-native/status-bar';

import { TabsPage } from '../pages/tabs/tabs';

Expand All @@ -11,12 +12,12 @@ import { TabsPage } from '../pages/tabs/tabs';
export class MyApp {
rootPage = TabsPage;

constructor(platform: Platform) {
constructor(platform: Platform, private splashScreen: SplashScreen, private statusbar: StatusBar ) {
platform.ready().then(() => {
// Okay, so the platform is ready and our plugins are available.
// Here you can do any higher level native things you might need.
StatusBar.styleDefault();
Splashscreen.hide();
statusbar.styleDefault();
splashScreen.hide();
});
}
}
12 changes: 11 additions & 1 deletion src/app/app.module.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
import { NgModule, ErrorHandler } from '@angular/core';
import { IonicApp, IonicModule, IonicErrorHandler } from 'ionic-angular';
import { BrowserModule } from '@angular/platform-browser';
import { MyApp } from './app.component';
import { AboutPage } from '../pages/about/about';
import { ContactPage } from '../pages/contact/contact';
import { HomePage } from '../pages/home/home';
import { TabsPage } from '../pages/tabs/tabs';
import { PostDetail } from '../pages/post-detail/post-detail';
import { HttpModule } from '@angular/http';
import { SplashScreen } from '@ionic-native/splash-screen';
import { StatusBar } from '@ionic-native/status-bar';

@NgModule({
declarations: [
Expand All @@ -17,6 +21,8 @@ import { PostDetail } from '../pages/post-detail/post-detail';
PostDetail
],
imports: [
BrowserModule,
HttpModule,
IonicModule.forRoot(MyApp)
],
bootstrap: [IonicApp],
Expand All @@ -28,6 +34,10 @@ import { PostDetail } from '../pages/post-detail/post-detail';
TabsPage,
PostDetail
],
providers: [{provide: ErrorHandler, useClass: IonicErrorHandler}]
providers: [
{provide: ErrorHandler, useClass: IonicErrorHandler},
SplashScreen,
StatusBar
]
})
export class AppModule {}
5 changes: 5 additions & 0 deletions src/app/main.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';

import { AppModule } from './app.module';

platformBrowserDynamic().bootstrapModule(AppModule);
2 changes: 1 addition & 1 deletion src/pages/about/about.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@
</ion-header>

<ion-content padding>

<p>I'm the about page!</p>
</ion-content>

0 comments on commit 241133d

Please sign in to comment.