I am new to gulp and I am wondering if what I want to achieve is practical or possible.
My projects structure:
root
|
components
| |
| component_1
|
Old question i know, but i been playing around in this area today, and hence came across this question. This may help someone if you are wanting to do something dynamic with the destination path.
You can supply a function as the argument to gulp.dest and hence do some pre processing on the destination path like this:
.pipe(gulp.dest(function (file) {
// file is the current file in the stream
// do something here
return pathString;
}));