Hello guys welcome back to my blog. Today in this blog post I am going to show you Remove duplicates from an Array in Reactjs JavaScript.
For reactjs new comers, please check the below link:
1. Guys here is the working code snippet and you can use this inside your react application:
var arr = ["apple", "bannana", "orange", "apple", "orange"]; arr = arr.filter( function( item, index, inputArray ) { return inputArray.indexOf(item) == index; });
I will appreciate that if you will tell your views for this post. Nothing matters if your views will be good or bad.
Jassa
Thanks
Recent Comments