SOURCE

function camelCase(str) {
  return str.replace(/_[a-z]/g, str1 => str1.substr(-1).toUpperCase())
}

let param = 'test_camel_case';
console.log('转换结果: ', camelCase(param));
console 命令行工具 X clear

                    
>
console