Created
August 26, 2022 14:43
-
-
Save snsxn/4ed22d0d82ca43d771d820d1d88cb289 to your computer and use it in GitHub Desktop.
One-line remove duplicates from an Array - JavaScript ES2015, ES6
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const removeDuplicates = (arr) => [...new Set(arr)]; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment