On my current HTML page, there is "Preferences" option through which user will get navigated to preferences page. I want to pass 1 parameter from prev. component to navigated component. account.component.html -
<button mat-menu-item [routerLink]="['/preferences']">
<mat-icon ngClass="material-icons-outlined">home</mat-icon>
<span>Preferences</span>
</button>
I want to pass accountNumber from this html to preferences.component.ts