index.js
/**
   * Simple/quick string formater. This will take an input string and apply n number of arguments to it.
   *
   * <b>example:</b><br />
   * <code>
   * <pre>
   *	var foo = excelFormulaUtilities.core.formatStr("{0}", "foo"); // foo will be set to "foo"
   *	var fooBar = excelFormulaUtilities.core.formatStr("{0} {1}", "foo", "bar"); // fooBar will be set to "fooBar"
   *	var error = excelFormulaUtilities.core.formatStr("{1}", "error"); // will throw an index out of range error since only 1 extra argument was passed, which would be index 0.
   * </pre>
   * </code>
   *
   * @memberOf global.excelFormulaUtilities.core
   * @function
   * @param {String} inStr
   **/
Simple/quick string formater. This will take an input string and apply n number of arguments to it.

@memberOf global.excelFormulaUtilities.core
@function
@param {String} inStr
Simple / quick string formater . This will take an input string and apply n number of arguments to it . @memberOf global . excelFormulaUtilities . core @function @param { String } inStr
static formatStr(inStr) {
    var formattedStr = inStr;
    var argIndex = 1;
    for (; argIndex < arguments.length; argIndex++) {
      var replaceIndex = argIndex - 1;
      var replaceRegex = new RegExp(
        "\\{{1}" + replaceIndex.toString() + "{1}\\}{1}",
        "g"
      );
      formattedStr = formattedStr.replace(replaceRegex, arguments[argIndex]);
    }
    return formattedStr;
  }
static formatStr ( inStr ) { var formattedStr = inStr ; var argIndex = 1 ; for ( ; argIndex < arguments . length ; argIndex ++ ) { var replaceIndex = argIndex - 1 ; var replaceRegex = new RegExp ( "\\{{1}" + replaceIndex . toString ( ) + "{1}\\}{1}" , "g" ) ; formattedStr = formattedStr . replace ( replaceRegex , arguments [ argIndex ] ) ; } return formattedStr ; }
Simple/quick string formater.
Simple / quick string formater .