I am trying to send href="#", using routerLink, but it is rendering %23 instead of #.
Not sure what is wrong.
<a routerLink={{item.url}}>item.linkname</a>
item = {
url: '#',
linkname:'abcd'
}
I am trying to send href="#", using routerLink, but it is rendering %23 instead of #.
Not sure what is wrong.
<a routerLink={{item.url}}>item.linkname</a>
item = {
url: '#',
linkname:'abcd'
}
Angular will always encode your URL with encodeURIComponent(). I do not understand what your intention is from a developer prespective but you can either:
href
instead of router link: <a [href]="item.url">{{ item.linkname }}</a>
.