I want to replace '[0' with '[' and '[1' with '['
var sign ='[[1,17.5,24],[0,17.5,25],[0,17.5,26],[0,17.5,31],,,,[0,280.5,47],[0,282.5,49]]';
sign.replace('[0,','[').replace('[1,', '[')
alert(sign)
but same value is there
Expected:[[17.5,24],[17.5,25],[17.5,26],[17.5,31],[280.5,47],[282.5,49]]
Please help