Skip to content

Commit b4fd7ac

Browse files
committed
fix:<Array> router change effect
1 parent 91f3970 commit b4fd7ac

File tree

1 file changed

+3
-9
lines changed

1 file changed

+3
-9
lines changed

src/app/components/NonprimitiveData/linear/arrays/array/array.component.ts

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,19 @@
1-
import { AfterViewInit, Component, ElementRef, OnInit } from '@angular/core';
2-
import { Router } from '@angular/router';
1+
import { Component, OnInit } from '@angular/core';
32
import { arrayData } from 'src/app/core/data-structures/linear/array/array-meta-data';
43

54
@Component({
65
selector: 'app-array',
76
templateUrl: './array.component.html',
87
styleUrls: ['./array.component.css']
98
})
10-
export class ArrayComponent implements OnInit, AfterViewInit {
9+
export class ArrayComponent implements OnInit {
1110
state = 0;
1211
arrayMetaData = arrayData;
1312
constructor(
14-
private router: Router,
15-
private elRef: ElementRef
1613
) { }
1714

1815
ngOnInit(): void {
19-
20-
}
21-
ngAfterViewInit(): void {
22-
this.tabChange(this.state);
16+
2317
}
2418
tabChange(index: number): void {
2519
this.state = index;

0 commit comments

Comments
 (0)