-
Notifications
You must be signed in to change notification settings - Fork 9
report() bug reproduced code. lifecycle, viewChild and angular syntax. #13
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
Closed
Closed
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
apps/angular/ionic-angular-standalone/src/app/issue/lifecycle/lifecycle.page.html
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<ion-header [translucent]="true"> | ||
<ion-toolbar> | ||
<ion-title>lifecycle</ion-title> | ||
</ion-toolbar> | ||
</ion-header> | ||
|
||
<ion-content [fullscreen]="true"> | ||
<ion-header collapse="condense"> | ||
<ion-toolbar> | ||
<ion-title size="large">lifecycle</ion-title> | ||
</ion-toolbar> | ||
</ion-header> | ||
</ion-content> |
Empty file.
17 changes: 17 additions & 0 deletions
17
apps/angular/ionic-angular-standalone/src/app/issue/lifecycle/lifecycle.page.spec.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { ComponentFixture, TestBed } from '@angular/core/testing'; | ||
import { LifecyclePage } from './lifecycle.page'; | ||
|
||
describe('LifecyclePage', () => { | ||
let component: LifecyclePage; | ||
let fixture: ComponentFixture<LifecyclePage>; | ||
|
||
beforeEach(async(() => { | ||
fixture = TestBed.createComponent(LifecyclePage); | ||
component = fixture.componentInstance; | ||
fixture.detectChanges(); | ||
})); | ||
|
||
it('should create', () => { | ||
expect(component).toBeTruthy(); | ||
}); | ||
}); |
34 changes: 34 additions & 0 deletions
34
apps/angular/ionic-angular-standalone/src/app/issue/lifecycle/lifecycle.page.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import { Component, OnInit } from '@angular/core'; | ||
import { CommonModule } from '@angular/common'; | ||
import { FormsModule } from '@angular/forms'; | ||
import { IonicModule, ViewWillEnter, ViewDidEnter, ViewWillLeave, ViewDidLeave } from '@ionic/angular'; | ||
|
||
@Component({ | ||
selector: 'app-lifecycle', | ||
templateUrl: './lifecycle.page.html', | ||
styleUrls: ['./lifecycle.page.scss'], | ||
standalone: true, | ||
imports: [IonicModule, CommonModule, FormsModule] | ||
}) | ||
/** | ||
* Error due to `@ionic/angular/standalone` not containing a lifecycle. | ||
*/ | ||
export class LifecyclePage implements OnInit, ViewWillEnter, ViewDidEnter, ViewWillLeave, ViewDidLeave { | ||
|
||
constructor() { } | ||
|
||
ngOnInit() { | ||
} | ||
|
||
ionViewWillEnter() { | ||
} | ||
|
||
ionViewDidEnter() { | ||
} | ||
|
||
ionViewWillLeave() { | ||
} | ||
|
||
ionViewDidLeave() { | ||
} | ||
} |
22 changes: 22 additions & 0 deletions
22
apps/angular/ionic-angular-standalone/src/app/issue/not-import-one/not-import-one.page.html
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<ion-header> | ||
<ion-toolbar> | ||
<ion-buttons slot="start" *ngIf="!isForce"><!-- I have checked to the point where ngIf is having an impact.--> | ||
sean-perkins marked this conversation as resolved.
Show resolved
Hide resolved
|
||
<ion-button><ion-icon name="close-outline" slot="icon-only"></ion-icon></ion-button> | ||
</ion-buttons> | ||
</ion-toolbar> | ||
</ion-header> | ||
|
||
<ion-content> | ||
<div class="ion-text-center ion-padding-top"> | ||
<ion-button | ||
class="medium-size" | ||
type="submit" | ||
shape="round" | ||
fill="outline" | ||
[disabled]="isLoading" | ||
> | ||
<ion-spinner slot="start" *ngIf="isSpinner"></ion-spinner> | ||
Login | ||
</ion-button> | ||
</div> | ||
</ion-content> |
Empty file.
17 changes: 17 additions & 0 deletions
17
...angular/ionic-angular-standalone/src/app/issue/not-import-one/not-import-one.page.spec.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { ComponentFixture, TestBed } from '@angular/core/testing'; | ||
import { NotImportOnePage } from './not-import-one.page'; | ||
|
||
describe('NotImportOnePage', () => { | ||
let component: NotImportOnePage; | ||
let fixture: ComponentFixture<NotImportOnePage>; | ||
|
||
beforeEach(async(() => { | ||
fixture = TestBed.createComponent(NotImportOnePage); | ||
component = fixture.componentInstance; | ||
fixture.detectChanges(); | ||
})); | ||
|
||
it('should create', () => { | ||
expect(component).toBeTruthy(); | ||
}); | ||
}); |
22 changes: 22 additions & 0 deletions
22
apps/angular/ionic-angular-standalone/src/app/issue/not-import-one/not-import-one.page.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import { Component, OnInit } from '@angular/core'; | ||
import { CommonModule } from '@angular/common'; | ||
import { FormsModule } from '@angular/forms'; | ||
import { IonicModule } from '@ionic/angular'; | ||
|
||
@Component({ | ||
selector: 'app-not-import-one', | ||
templateUrl: './not-import-one.page.html', | ||
styleUrls: ['./not-import-one.page.scss'], | ||
standalone: true, | ||
imports: [IonicModule, CommonModule, FormsModule] | ||
}) | ||
export class NotImportOnePage implements OnInit { | ||
isForce = false; | ||
isLoading = false; | ||
isSpinner = false; | ||
constructor() { } | ||
|
||
ngOnInit() { | ||
} | ||
|
||
} |
13 changes: 13 additions & 0 deletions
13
apps/angular/ionic-angular-standalone/src/app/issue/view-child/view-child.page.html
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<ion-header [translucent]="true"> | ||
<ion-toolbar> | ||
<ion-title>view-child</ion-title> | ||
</ion-toolbar> | ||
</ion-header> | ||
|
||
<ion-content [fullscreen]="true"> | ||
<ion-header collapse="condense"> | ||
<ion-toolbar> | ||
<ion-title size="large">view-child</ion-title> | ||
</ion-toolbar> | ||
</ion-header> | ||
</ion-content> |
Empty file.
17 changes: 17 additions & 0 deletions
17
apps/angular/ionic-angular-standalone/src/app/issue/view-child/view-child.page.spec.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { ComponentFixture, TestBed } from '@angular/core/testing'; | ||
import { ViewChildPage } from './view-child.page'; | ||
|
||
describe('ViewChildPage', () => { | ||
let component: ViewChildPage; | ||
let fixture: ComponentFixture<ViewChildPage>; | ||
|
||
beforeEach(async(() => { | ||
fixture = TestBed.createComponent(ViewChildPage); | ||
component = fixture.componentInstance; | ||
fixture.detectChanges(); | ||
})); | ||
|
||
it('should create', () => { | ||
expect(component).toBeTruthy(); | ||
}); | ||
}); |
24 changes: 24 additions & 0 deletions
24
apps/angular/ionic-angular-standalone/src/app/issue/view-child/view-child.page.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import {Component, OnInit, ViewChild} from '@angular/core'; | ||
import { CommonModule } from '@angular/common'; | ||
import { FormsModule } from '@angular/forms'; | ||
import {IonContent, IonicModule} from '@ionic/angular'; | ||
sean-perkins marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
@Component({ | ||
selector: 'app-view-child', | ||
templateUrl: './view-child.page.html', | ||
styleUrls: ['./view-child.page.scss'], | ||
standalone: true, | ||
imports: [IonicModule, CommonModule, FormsModule] | ||
}) | ||
export class ViewChildPage implements OnInit { | ||
/** | ||
* Referencing the template's ion-content results in a double call. | ||
*/ | ||
@ViewChild(IonContent) | ||
content!: IonContent; | ||
|
||
constructor() { } | ||
|
||
ngOnInit() { | ||
} | ||
} |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Error due to
@ionic/angular/standalone
not containing a lifecycle.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks to be a missing set of exports from Ionic Framework. This will be addressed here: ionic-team/ionic-framework#28346!