SyntaxFix
Write A Post
Hire A Developer
Questions
You can use :
const intersection = array1.filter(element => array2.includes(element));