1.0.0 • Published 2 years ago

1811a-demo1.13 v1.0.0

Weekly downloads
1
License
ISC
Repository
-
Last release
2 years ago

#嵌套数组进行扁平化处理

let arr1 = [];

function steamroller(arr) {
    for (let i of arr) {
        Array.isArray(i) ? steamroller(i) : arr1.push(i);
    }
    return arr1;
}
1.0.0

2 years ago