JavaScript flat() Method