I have a function on my site that takes a array of email strings and removes any duplicates. But it doesn't work on ie because of my use of the Array.from method. How can I convert to following code to work on ie?
let emailsListArray = ['reece@gmail.com', 'someone@gmail.com', 'another@gmail.com', 'reece@gmail.com', 'person@gmail.com', 'another@gmail.com'];
Array.prototype.unique = function() {
return Array.from(new Set(this));
}
emailsListArray = emailsListArray.unique();
console.log(emailsListArray);
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>