0

I am a beginner in AngularJS and I'm having some issues using the ng-href.

I have an array containing dictionaries.

$scope.options = [{title: 'option1', path:'optionPage'}, ... ];

In the HTML code, I make use of ng-repeat within a <table></table> to display options; each row being a link. Below is the code.

<table class="table">
     <tr ng-repeat="option in options">
        <td><a href="#optionPage">{{option.title}}</a></td> <!-- This works -->
        <td><a ng-href="#{{option.path}}">{{option.title}}</a></td> <!-- This does not work!! -->
     </tr>
  </table>

Using the a href and directly providing the link works. (I am making use of the $route), but ng-href doesn't work. Could somebody please point out the issue here.

Adithya
  • 4,545
  • 3
  • 25
  • 28

1 Answers1

0

Solution provided in the below link helped me solve my problem. https://stackoverflow.com/a/15769779/1029360

The chrome-extension: protocol needs to be whitelisted before use.

Community
  • 1
  • 1
Adithya
  • 4,545
  • 3
  • 25
  • 28