UNPKG

zarbis

Version:

Configuration-less build tool

17 lines 681 B
const aliasList = process.env.ZARBIS_ALIASES; let __resolveFilename = module.constructor._resolveFilename; module.constructor._resolveFilename = function (filename, e, f) { let splitPath = filename.split("/"); let isNamespaced = "@" === filename[0]; let moduleName = isNamespaced ? splitPath[0] + "/" + splitPath[1] : splitPath[0]; if (aliasList[moduleName]) { if (isNamespaced) splitPath.splice(0, 2, aliasList[moduleName]); else splitPath[0] = aliasList[moduleName]; filename = splitPath.join("/"); } return __resolveFilename.call(this, filename, e, f); }; export {}; //# sourceMappingURL=nodeSupport.js.map