code: function getLocationFromIndex(string, index) {
    const lines = string.split('\n');
    let destructure = false;
    let idx = 0;
    const results = [];
    let found = [];
  
    // Convert to batch
    if (!Array.isArray(index)) {
      index = [index];
      destructure = true;
    }
  
    for (let i = 0, l = lines.length; i < l; i++) {
      const m = index.length;
      const line = lines[i];
      // Add removed line ending
      const lineLength = line.length + 1;
  
      // Abort if no more indexes
      if (!m) break;
  
      // Loop through remaining indexes
      for (let j = 0; j < m; j++) {
        // Store result if index in current line
        if (idx + lineLength > index[j]) {
          results.push({
            line: i + 1,
            column: index[j] - idx
          });
          // Store matched index for later removal
          found.push(j);
        }
      }
  
      if (found.length) {
        for (let k = 0, n = found.length; k < n; k++) {
          // Remove index (correct for previous removals)
          index.splice(found[k] - k, 1);
        }
        found = [];
      }
      idx += lineLength;
    }
  
    if (results.length) return destructure ? results[0] : results;
    return { line: 0, column: 0 };
  }
docs: Retrieve line/column from 'index' of 'string'
  Column is zero-indexed
  @param {String} string
  @param {Number} index
  @returns {Object}