Skip to content

Latest commit

 

History

History
executable file
·
10 lines (7 loc) · 224 Bytes

File metadata and controls

executable file
·
10 lines (7 loc) · 224 Bytes

.join([separator])

Adds all the elements of an array separated by the specified separator string.

const a = [0, 1, 2, 3, 4];
const b = a.join("-");      // "0-1-2-3-4"

The default is a comma (",").