gulp-es6-module-transpiler icon indicating copy to clipboard operation
gulp-es6-module-transpiler copied to clipboard

Removed dirtyness which led to a require error

Open denysvitali opened this issue 8 years ago • 3 comments

Error: Cannot find module 'es6-module-transpiler/node_modules/recast'

I fixed by requiring the module recast without the es6-module-transpiler path and haven't found any problem at all. Was it really necessary to bind the module to the local path? And what about using __dirname or any package.json trick?

denysvitali avatar Mar 12 '16 18:03 denysvitali

I did this in all my builds at least 2 months ago with no adverse affects, someone merge this in

sicdigital avatar Apr 11 '16 17:04 sicdigital

I have the same problem, encounter the same error message. On a Windows 10 laptop.

I've now manually applied this patch (the var recast = require('recast'); line only), to be able to run the transpiler on this computer. Seems to work fine (this far).

B.t.w., esnext/es6-module-transpiler declares itself deprecated, says "This project been deprecated in favor of Babel & Rollup" (https://github.com/esnext/es6-module-transpiler ) — perhaps what I should do, then, isn't to wait for this PR to get merged? But rather try to switch to gulp-babel?

kajmagnus79 avatar Jun 10 '16 07:06 kajmagnus79

Gulp-Babel is also deprecated, I switched over to Browserify with the babelify transform. It works great.

sicdigital avatar Jun 10 '16 08:06 sicdigital