babel-preset-diffhtml-imports
Advanced tools
Comparing version 1.0.0-beta.11 to 1.0.0-beta.13
{ | ||
"name": "babel-preset-diffhtml-imports", | ||
"version": "1.0.0-beta.11", | ||
"version": "1.0.0-beta.13", | ||
"description": "Used to normalize import paths to diffHTML modules based on env", | ||
@@ -30,3 +30,3 @@ "main": "index.js", | ||
}, | ||
"gitHead": "1567bc7d5a3d352eb661f630409b4e079f2ce211" | ||
"gitHead": "4cab34c151aad67edadbdc044c9f45b63e9a3baa" | ||
} |
@@ -28,3 +28,3 @@ const { extname, dirname, join, relative } = require('path'); | ||
else if (file) { | ||
newPath = `../../../../diffhtml/${file}`; | ||
newPath = `diffhtml/${file}`; | ||
} | ||
@@ -39,21 +39,4 @@ else if (sub2) { | ||
newPath = relative(dirname(filePath), join(path, newPath)); | ||
// TODO Remove me... | ||
//if (newPath[0] !== '.') { | ||
// newPath = `${newPath}`; | ||
//} | ||
// Ensure folders get a trailing slash. | ||
//if (!newPath.includes('.js') && newPath[--newPath.length] !== '/' && newPath.slice(-5) !== 'index') { | ||
// newPath += '/index.js'; | ||
//} | ||
// Lastly ensure an extension has been added or is a path. | ||
//if (!extname(newPath)) { | ||
// newPath += '.js'; | ||
//} | ||
return newPath; | ||
}); | ||
} |
6172
106