code: function _clearRepeat(str) {
    let ret = '',
      i = 0,
      l = str.length,
      char;
  
    for (; i < l; i++) {
      char = str[i];
      if (ret.indexOf(char) < 0) {
        ret += char;
      }
    }
  
    return ret;
  }
docs: Clear the repeated characters