mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-23 14:01:20 +08:00
test(ngmodule): update to ngmodule
This commit is contained in:
@ -1,12 +1,12 @@
|
||||
import { Component, ViewChild } from '@angular/core';
|
||||
import { Component, ViewChild, NgModule } from '@angular/core';
|
||||
import { Http } from '@angular/http';
|
||||
import { ionicBootstrap, Slides } from '../../../../../src';
|
||||
import { IonicApp, IonicModule, Slides } from '../../../..';
|
||||
|
||||
|
||||
@Component({
|
||||
templateUrl: 'main.html'
|
||||
})
|
||||
class E2EApp {
|
||||
export class E2EApp {
|
||||
mySlideOptions: any;
|
||||
images: string[] = [];
|
||||
@ViewChild(Slides) slider: Slides;
|
||||
@ -43,4 +43,16 @@ class E2EApp {
|
||||
|
||||
}
|
||||
|
||||
ionicBootstrap(E2EApp);
|
||||
@NgModule({
|
||||
declarations: [
|
||||
E2EApp
|
||||
],
|
||||
imports: [
|
||||
IonicModule.forRoot(E2EApp)
|
||||
],
|
||||
bootstrap: [IonicApp],
|
||||
entryComponents: [
|
||||
E2EApp
|
||||
]
|
||||
})
|
||||
export class AppModule {}
|
@ -1,11 +1,11 @@
|
||||
import { Component, ViewChild } from '@angular/core';
|
||||
import { ionicBootstrap, Slides } from '../../../../../src';
|
||||
import { Component, ViewChild, NgModule } from '@angular/core';
|
||||
import { IonicApp, IonicModule, Slides } from '../../../..';
|
||||
|
||||
|
||||
@Component({
|
||||
templateUrl: 'main.html'
|
||||
})
|
||||
class MyPage {
|
||||
export class MyPage {
|
||||
@ViewChild('mySlider') slider: Slides;
|
||||
mySlideOptions = {
|
||||
initialSlide: 1,
|
||||
@ -49,8 +49,22 @@ class MyPage {
|
||||
@Component({
|
||||
template: `<ion-nav [root]="root"></ion-nav>`
|
||||
})
|
||||
class E2EApp {
|
||||
export class E2EApp {
|
||||
root: any = MyPage;
|
||||
}
|
||||
|
||||
ionicBootstrap(E2EApp);
|
||||
@NgModule({
|
||||
declarations: [
|
||||
E2EApp,
|
||||
MyPage
|
||||
],
|
||||
imports: [
|
||||
IonicModule.forRoot(E2EApp)
|
||||
],
|
||||
bootstrap: [IonicApp],
|
||||
entryComponents: [
|
||||
E2EApp,
|
||||
MyPage
|
||||
]
|
||||
})
|
||||
export class AppModule {}
|
@ -1,11 +1,11 @@
|
||||
import { Component } from '@angular/core';
|
||||
import { ionicBootstrap, NavController } from '../../../../../src';
|
||||
import { Component, NgModule } from '@angular/core';
|
||||
import { IonicApp, IonicModule, NavController } from '../../../..';
|
||||
|
||||
|
||||
@Component({
|
||||
templateUrl: 'main.html'
|
||||
})
|
||||
class IntroPage {
|
||||
export class IntroPage {
|
||||
continueText: string = 'Skip';
|
||||
startingIndex: number = 1;
|
||||
mySlideOptions: any;
|
||||
@ -55,14 +55,30 @@ class IntroPage {
|
||||
</ion-content>
|
||||
`
|
||||
})
|
||||
class MainPage {}
|
||||
export class MainPage {}
|
||||
|
||||
|
||||
@Component({
|
||||
template: '<ion-nav [root]="root"></ion-nav>'
|
||||
})
|
||||
class E2EApp {
|
||||
export class E2EApp {
|
||||
root = IntroPage;
|
||||
}
|
||||
|
||||
ionicBootstrap(E2EApp);
|
||||
@NgModule({
|
||||
declarations: [
|
||||
E2EApp,
|
||||
IntroPage,
|
||||
MainPage
|
||||
],
|
||||
imports: [
|
||||
IonicModule.forRoot(E2EApp)
|
||||
],
|
||||
bootstrap: [IonicApp],
|
||||
entryComponents: [
|
||||
E2EApp,
|
||||
IntroPage,
|
||||
MainPage
|
||||
]
|
||||
})
|
||||
export class AppModule {}
|
@ -1,11 +1,11 @@
|
||||
import { Component, ViewChild } from '@angular/core';
|
||||
import { ionicBootstrap, Slides } from '../../../../../src';
|
||||
import { Component, ViewChild, NgModule } from '@angular/core';
|
||||
import { IonicApp, IonicModule, Slides } from '../../../..';
|
||||
|
||||
|
||||
@Component({
|
||||
templateUrl: 'main.html'
|
||||
})
|
||||
class E2EApp {
|
||||
export class E2EApp {
|
||||
slides: any[];
|
||||
@ViewChild('loopSlider') loopSlider: Slides;
|
||||
startingIndex: number;
|
||||
@ -44,4 +44,16 @@ class E2EApp {
|
||||
|
||||
}
|
||||
|
||||
ionicBootstrap(E2EApp);
|
||||
@NgModule({
|
||||
declarations: [
|
||||
E2EApp
|
||||
],
|
||||
imports: [
|
||||
IonicModule.forRoot(E2EApp)
|
||||
],
|
||||
bootstrap: [IonicApp],
|
||||
entryComponents: [
|
||||
E2EApp
|
||||
]
|
||||
})
|
||||
export class AppModule {}
|
22
src/components/slides/test/scroll/app-module.ts
Normal file
22
src/components/slides/test/scroll/app-module.ts
Normal file
@ -0,0 +1,22 @@
|
||||
import { Component, NgModule } from '@angular/core';
|
||||
import { IonicApp, IonicModule } from '../../../..';
|
||||
|
||||
|
||||
@Component({
|
||||
templateUrl: 'main.html'
|
||||
})
|
||||
export class E2EApp {}
|
||||
|
||||
@NgModule({
|
||||
declarations: [
|
||||
E2EApp
|
||||
],
|
||||
imports: [
|
||||
IonicModule.forRoot(E2EApp)
|
||||
],
|
||||
bootstrap: [IonicApp],
|
||||
entryComponents: [
|
||||
E2EApp
|
||||
]
|
||||
})
|
||||
export class AppModule {}
|
@ -1,10 +0,0 @@
|
||||
import { Component } from '@angular/core';
|
||||
import { ionicBootstrap } from '../../../../../src';
|
||||
|
||||
|
||||
@Component({
|
||||
templateUrl: 'main.html'
|
||||
})
|
||||
class E2EApp {}
|
||||
|
||||
ionicBootstrap(E2EApp);
|
Reference in New Issue
Block a user