I want to display only uniq values when I'm using filter
For example, I have this:
const test = 'This is Right';
const test1 = 'This is wrong';
const test2 = 'This is Right';
const test3 = 'The word is hello'
const result = [test, test1, test2, test3].filter(value => value).join(' - ');
console.log(result);
The output is:
This is Right - This is wrong - This is Right - The word is hello
What I want :
This is Right - This is wrong - The word is hello
I already see some same issues but I don't wanna work with array. Thanks for your help