code: function replaceAll(str = '', pattern, replacement) {
  	if (arguments.length < 2 ){
  		return str;
  	}
  
  	let rs = str;
  	if (lodash.isPlainObject(pattern)){
  		for (let key in pattern){
  			rs = rs.replace(new RegExp('{' + key + '}', "gm"), pattern[key])
  		}
  	}else {
  		rs = rs.replace(new RegExp(pattern, "gm"), replacement)
  	}
  
  	return rs;
  }
docs: 字符串全部替换
  <p>
  当pattern为普通对象时，按对象键值替换
  
  @param {String} str 原字符串
  @param {String/PlainObject} pattern 待替换内容 （当pattern为普通对象时，按对象键值替换）
  @param {String} replacement 替换后内容
  @return 替换结果