lib/adjust-source-map.js
function copyAndOffsetMapping(existingMapping) {
    var column     = getColumnAfter(existingMapping.generatedLine - 1, existingMapping.generatedColumn);
    var newMapping = {
      generated: {
        line  : existingMapping.generatedLine,
        column: column
      }
    };
    if (existingMapping.source) {
      newMapping.source   = existingMapping.source;
      newMapping.original = {
        line  : existingMapping.originalLine,
        column: existingMapping.originalColumn
      };
      if (existingMapping.name) {
        newMapping.name = existingMapping.name;
      }
    }
    generator.addMapping(newMapping);
  }
function copyAndOffsetMapping(existingMapping) {
    var column     = getColumnAfter(existingMapping.generatedLine - 1, existingMapping.generatedColumn);
    var newMapping = {
      generated: {
        line  : existingMapping.generatedLine,
        column: column
      }
    };
    if (existingMapping.source) {
      newMapping.source   = existingMapping.source;
      newMapping.original = {
        line  : existingMapping.originalLine,
        column: existingMapping.originalColumn
      };
      if (existingMapping.name) {
        newMapping.name = existingMapping.name;
      }
    }
    generator.addMapping(newMapping);
  }
function copyAndOffsetMapping ( existingMapping ) { var column = getColumnAfter ( existingMapping . generatedLine - 1 , existingMapping . generatedColumn ) ; var newMapping = { generated : { line : existingMapping . generatedLine , column : column } } ; if ( existingMapping . source ) { newMapping . source = existingMapping . source ; newMapping . original = { line : existingMapping . originalLine , column : existingMapping . originalColumn } ; if ( existingMapping . name ) { newMapping . name = existingMapping . name ; } } generator . addMapping ( newMapping ) ; }
Copy the given mapping but offset as indicated by the split source code.
@param {object} existingMapping An existing source-map mapping from a source-map consumer
Copy the given mapping but offset as indicated by the split source code .