File tree Expand file tree Collapse file tree 10 files changed +30
-48
lines changed
static/usage/v6/back-button Expand file tree Collapse file tree 10 files changed +30
-48
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1
1
``` ts
2
2
import { Component } from ' @angular/core' ;
3
-
3
+ import { IonicModule } from ' @ionic/angular ' ;
4
4
import { PageOneComponent } from ' ./page-one.component' ;
5
5
6
6
@Component ({
7
7
selector: ' app-example' ,
8
8
templateUrl: ' example.component.html' ,
9
+ imports: [IonicModule ],
10
+ standalone: true
9
11
})
10
12
export class ExampleComponent {
11
13
component = PageOneComponent ;
Original file line number Diff line number Diff line change 1
1
``` ts
2
2
import { Component } from ' @angular/core' ;
3
-
3
+ import { IonicModule } from ' @ionic/angular ' ;
4
4
import { PageTwoComponent } from ' ./page-two.component' ;
5
5
6
6
@Component ({
@@ -19,6 +19,8 @@ import { PageTwoComponent } from './page-two.component';
19
19
</ion-nav-link>
20
20
</ion-content>
21
21
` ,
22
+ imports: [IonicModule ],
23
+ standalone: true
22
24
})
23
25
export class PageOneComponent {
24
26
component = PageTwoComponent ;
Original file line number Diff line number Diff line change 1
1
``` ts
2
2
import { Component } from ' @angular/core' ;
3
+ import { IonicModule } from ' @ionic/angular' ;
3
4
4
5
@Component ({
5
6
selector: ' app-page-two' ,
@@ -17,6 +18,8 @@ import { Component } from '@angular/core';
17
18
<p>Use the back button to navigate to the previous page.</p>
18
19
</ion-content>
19
20
` ,
21
+ imports: [IonicModule ],
22
+ standalone: true
20
23
})
21
24
export class PageTwoComponent {}
22
25
```
Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ import Playground from '@site/src/components/global/Playground';
2
2
3
3
import javascript from './javascript.md';
4
4
5
- import angular_app_module_ts from './angular/app_module_ts.md';
6
5
import angular_example_component_html from './angular/example_component_html.md';
7
6
import angular_example_component_ts from './angular/example_component_ts.md';
8
7
import angular_page_one_component_ts from './angular/page_one_component_ts.md';
@@ -26,7 +25,6 @@ import vue_page_two from './vue/page_two_vue.md';
26
25
'src/app/example.component.ts': angular_example_component_ts,
27
26
'src/app/page-one.component.ts': angular_page_one_component_ts,
28
27
'src/app/page-two.component.ts': angular_page_two_component_ts,
29
- 'src/app/app.module.ts': angular_app_module_ts,
30
28
},
31
29
},
32
30
react: {
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1
1
``` ts
2
2
import { Component } from ' @angular/core' ;
3
+ import { IonicModule } from ' @ionic/angular' ;
3
4
4
5
import { PageOneComponent } from ' ./page-one.component' ;
5
6
6
7
@Component ({
7
8
selector: ' app-example' ,
8
9
templateUrl: ' example.component.html' ,
10
+ imports: [IonicModule ],
11
+ standalone: true
9
12
})
10
13
export class ExampleComponent {
11
14
component = PageOneComponent ;
Original file line number Diff line number Diff line change 1
1
``` ts
2
2
import { Component } from ' @angular/core' ;
3
-
3
+ import { IonicModule } from ' @ionic/angular ' ;
4
4
import { PageTwoComponent } from ' ./page-two.component' ;
5
5
6
6
@Component ({
@@ -19,6 +19,8 @@ import { PageTwoComponent } from './page-two.component';
19
19
</ion-nav-link>
20
20
</ion-content>
21
21
` ,
22
+ imports: [IonicModule ],
23
+ standalone: true
22
24
})
23
25
export class PageOneComponent {
24
26
component = PageTwoComponent ;
Original file line number Diff line number Diff line change 1
1
``` ts
2
2
import { Component } from ' @angular/core' ;
3
+ import { IonicModule } from ' @ionic/angular' ;
4
+ import { addIcons } from ' ionicons' ;
5
+ import { caretBack } from ' ionicons/icons' ;
3
6
4
7
@Component ({
5
8
selector: ' app-page-two' ,
@@ -17,6 +20,17 @@ import { Component } from '@angular/core';
17
20
<p>Use the back button to navigate to the previous page.</p>
18
21
</ion-content>
19
22
` ,
23
+ imports: [IonicModule ],
24
+ standalone: true
20
25
})
21
- export class PageTwoComponent {}
26
+ export class PageTwoComponent {
27
+ constructor () {
28
+ /**
29
+ * Any icons you want to use in your application
30
+ * can be registered in app.component.ts and then
31
+ * referenced by name anywhere in your application.
32
+ */
33
+ addIcons ({ caretBack });
34
+ }
35
+ }
22
36
```
Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ import Playground from '@site/src/components/global/Playground';
2
2
3
3
import javascript from './javascript.md';
4
4
5
- import angular_app_module_ts from './angular/app_module_ts.md';
6
5
import angular_example_component_html from './angular/example_component_html.md';
7
6
import angular_example_component_ts from './angular/example_component_ts.md';
8
7
import angular_page_one_component_ts from './angular/page_one_component_ts.md';
@@ -26,7 +25,6 @@ import vue_page_two from './vue/page_two_vue.md';
26
25
'src/app/example.component.ts': angular_example_component_ts,
27
26
'src/app/page-one.component.ts': angular_page_one_component_ts,
28
27
'src/app/page-two.component.ts': angular_page_two_component_ts,
29
- 'src/app/app.module.ts': angular_app_module_ts,
30
28
},
31
29
},
32
30
react: {
You can’t perform that action at this time.
0 commit comments