Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
var traceur = require('traceur');
var ParseTreeTransformer = traceur.get('codegeneration/ParseTreeTransformer.js').ParseTreeTransformer;
var ModuleSpecifier = traceur.get('syntax/trees/ParseTrees.js').ModuleSpecifier;
var createStringLiteralToken = traceur.get('codegeneration/ParseTreeFactory.js').createStringLiteralToken;
function TraceurImportNormalizeTransformer(map) {
this.map = map;
return ParseTreeTransformer.apply(this, arguments);
}
TraceurImportNormalizeTransformer.prototype = Object.create(ParseTreeTransformer.prototype);
TraceurImportNormalizeTransformer.prototype.transformModuleSpecifier = function(tree) {
var depName = this.map(tree.token.processedValue) || tree.token.processedValue;
return new ModuleSpecifier(tree.location, createStringLiteralToken(depName));
};
exports.TraceurImportNormalizeTransformer = TraceurImportNormalizeTransformer;
var traceur = require('traceur');
var ParseTreeTransformer = traceur.get('codegeneration/ParseTreeTransformer.js').ParseTreeTransformer;
var ModuleSpecifier = traceur.get('syntax/trees/ParseTrees.js').ModuleSpecifier;
var createStringLiteralToken = traceur.get('codegeneration/ParseTreeFactory.js').createStringLiteralToken;
function TraceurImportNormalizeTransformer(map) {
this.map = map;
return ParseTreeTransformer.apply(this, arguments);
}
TraceurImportNormalizeTransformer.prototype = Object.create(ParseTreeTransformer.prototype);
TraceurImportNormalizeTransformer.prototype.transformModuleSpecifier = function(tree) {
var depName = this.map(tree.token.processedValue) || tree.token.processedValue;
return new ModuleSpecifier(tree.location, createStringLiteralToken(depName));
};
exports.TraceurImportNormalizeTransformer = TraceurImportNormalizeTransformer;
var traceur = require('traceur');
var ParseTreeTransformer = traceur.get('codegeneration/ParseTreeTransformer.js').ParseTreeTransformer;
var ModuleSpecifier = traceur.get('syntax/trees/ParseTrees.js').ModuleSpecifier;
var createStringLiteralToken = traceur.get('codegeneration/ParseTreeFactory.js').createStringLiteralToken;
function TraceurImportNormalizeTransformer(map) {
this.map = map;
return ParseTreeTransformer.apply(this, arguments);
}
TraceurImportNormalizeTransformer.prototype = Object.create(ParseTreeTransformer.prototype);
TraceurImportNormalizeTransformer.prototype.transformModuleSpecifier = function(tree) {
var depName = this.map(tree.token.processedValue) || tree.token.processedValue;
return new ModuleSpecifier(tree.location, createStringLiteralToken(depName));
};
exports.TraceurImportNormalizeTransformer = TraceurImportNormalizeTransformer;
function remap(source, map, fileName) {