deepak1556 / gulp-browserify

Bundle modules with BrowserifyJS
MIT License
195 stars 45 forks source link

TypeError: Arguments to path.join must be strings #15

Closed karellm closed 10 years ago

karellm commented 10 years ago

Hi,

I'm trying to run gulp-browserify but I get the following error: TypeError: Arguments to path.join must be strings

[gulp] Running 'browserify'...

path.js:360
        throw new TypeError('Arguments to path.join must be strings');
              ^
TypeError: Arguments to path.join must be strings
    at path.js:360:15
    at Array.filter (native)
    at Object.exports.join (path.js:358:36)
    at Stream.endStream (/Users/me/project/node_modules/gulp-concat/index.js:30:27)
    at _end (/Users/me/project/node_modules/gulp-concat/node_modules/through/index.js:65:9)
    at Stream.stream.end (/Users/me/project/node_modules/gulp-concat/node_modules/through/index.js:74:5)
    at Stream.onend (stream.js:79:10)
    at Stream.EventEmitter.emit (events.js:117:20)
    at end (/Users/me/project/node_modules/gulp/node_modules/map-stream/index.js:108:39)
    at queueData (/Users/me/project/node_modules/gulp/node_modules/map-stream/index.js:57:17)
    at next (/Users/me/project/node_modules/gulp/node_modules/map-stream/index.js:68:5)
    at /Users/me/project/node_modules/gulp/node_modules/map-stream/index.js:77:7
    at /Users/me/project/node_modules/gulp/lib/createInputStream/bufferFile.js:7:5
    at fs.js:266:14
    at /Users/me/project/node_modules/gulp/node_modules/graceful-fs/graceful-fs.js:103:5
    at Object.oncomplete (fs.js:107:15)

My Gulpfile browserify task:

gulp.task 'browserify', ['coffee'], ->
  gulp.src('demo/scripts/myproject.js')
    .pipe(browserify({insertGlobals : true, debug: true}).on('error', gutil.log))
    .pipe(concat('myproject-bundle.js'))
    .pipe(gulp.dest('./demo/'))

Any idea what is going on? Thanks!

deepak1556 commented 10 years ago

i really cant think of anything other than checking your gulp-concat version. Also i found a setup that would be similar to your use case and it seem to be working fine https://github.com/davemo/react-battleplanner/blob/master/gulpfile.coffee . can check it out and update the issue?

karellm commented 10 years ago

How to require browserify to waste time on debugging: browserify = require('gulp-concat')

One of those... I think it is time to call it for today. Sorry for the trouble.

ORESoftware commented 9 years ago

dynamic typing FTW