source:
imaps-frontend/node_modules/clean-css/lib/utils/clone-array.js
Last change on this file was 79a0317, checked in by , 4 days ago | |
---|---|
|
|
File size: 239 bytes |
Rev | Line | |
---|---|---|
[79a0317] | 1 | function cloneArray(array) { |
2 | var cloned = array.slice(0); | |
3 | ||
4 | for (var i = 0, l = cloned.length; i < l; i++) { | |
5 | if (Array.isArray(cloned[i])) { cloned[i] = cloneArray(cloned[i]); } | |
6 | } | |
7 | ||
8 | return cloned; | |
9 | } | |
10 | ||
11 | module.exports = cloneArray; |
Note:
See TracBrowser
for help on using the repository browser.