$scope.articles = [
{
link: "http://google.com",
source: "Google",
title: "hello",
"date": new Date(2008, 4, 15)
},
];
<tbody>
<tr ng-repeat = "article in articles | orderBy:sortType:sortReverse | filter:searchArticle ">
<td>{{article.source}}</td>
<td><a href="{{article.link}}" target="_blank" rel="noopener noreferrer">{{article.title}}</a></td>
<td class="date-table-td">{{article.date | date:'longDate'}}</td>
</tr>
</tbody><!-- End table body -->
Hey there! I've got this code snippet and it's displaying the date as May 15, 2008. Do you know how I can modify it to show just the year or maybe only the year and month?
Appreciate any help with this. Thank you!