How to free a two dimensional array in javascript

This is an example. Values can be text, numbers, or more values.

var aa=[[1,2],[[3,4],[3,4]],[1,2],[1,2]]

This is the result I want.

[[1,2],[3,4],[3,4],[1,2],[1,2]]

I tried using filter to get the result, but it failed…