Title: How can I get the value of ng-repeat when clicking on it
Tags: angularjs;angularjs-ng-repeat
Question: Can anybody help me in getting the ng-repeat value while we click on it.

```<ul ng-repeat="section in sections"&gt;
<li&gt;
  <a href='#'&gt;{{section.name}}</a&gt;
</li&gt;
<ul&gt;
```

Comment: A directive would give easy, clean access.

Here is the accepted answer: Take a look at this example I've made: http://jsbin.com/UWodob/1/ using ng-click you can get the value of the item being clicked.



{'source': 'StackExchangeDataset', 'subset': 'stackoverflow.com', 'metadata': {'AnswerCount': 1, 'CommentCount': 1, 'ContentLicense': 'CC BY-SA 3.0', 'CreationDate': '2013:00:09/20/13', 'FavoriteCount': None, 'PostTypeId': 1, 'Tags': '<angularjs><angularjs-ng-repeat>', 'Title': 'How can I get the value of ng-repeat when clicking on it', 'ViewCount': 820, 'id': 18908480, 'user_AboutMe': '', 'user_AccountId': 2990113.0, 'user_DisplayName': 'babtech', 'user_Reputation': 159.0, 'user_Views': 27.0, 'user_id': 2537843.0}}