Reputation: 1165
Am loving browserify-rails with babel es6 support! But I am troubled by errors like this one because there's no mention of the original source file location so very difficult for me to debug/fix. Clearly this (below) is just a botched require/import/export in a .js file, but without reference to the source path, it takes a lot of sleuthing to fix... What am I missing?
Started GET "/" for 127.0.0.1 at 2016-04-20 06:00:00 -0700
ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"
Processing by ClientController#load as HTML
Rendered client/load.html.erb within layouts/client (1.6ms)
Browserify: /Users/eric/Dropbox/calcium/node_modules/.bin/browserifyinc -d --transform babelify --list --cachefile=/Users/eric/Dropbox/calcium/tmp/cache/browserify-rails/browserifyinc-cache.json -o "/Users/eric/Dropbox/calcium/tmp/cache/browserify-rails/output20160420-21848-1xfzor9" -
Completed 500 Internal Server Error in 361ms (ActiveRecord: 0.0ms)
ActionView::Template::Error (Error while running `/Users/eric/Dropbox/calcium/node_modules/.bin/browserifyinc -d --transform babelify --list --cachefile=/Users/eric/Dropbox/calcium/tmp/cache/browserify-rails/browserifyinc-cache.json -o "/Users/eric/Dropbox/calcium/tmp/cache/browserify-rails/output20160420-21848-1xfzor9" -`:
module.js:328
throw err;
^
Error: Cannot find module '../'
at Function.Module._resolveFilename (module.js:326:15)
at Function.Module._load (module.js:277:25)
at Module.require (module.js:354:17)
at require (internal/module.js:12:17)
at Object.<anonymous> (/Users/eric/Dropbox/calcium/node_modules/.bin/browserifyinc:3:29)
at Module._compile (module.js:410:26)
at Object.Module._extensions..js (module.js:417:10)
at Module.load (module.js:344:32)
at Function.Module._load (module.js:301:12)
at Function.Module.runMain (module.js:442:10)
):
Upvotes: 2
Views: 130