0

How can I compile all files from specified folders (and its sub-folders) in place?

E.g. in case of TypeScript to JavaScript compilation:

[before]

/
/src
/src/app.ts
/lib
/lib/lib.ts

[after]

/
/src
/src/app.ts
/src/app.js
/lib
/lib/lib.ts
/lib/lib.js
  • Without specifying 2 separate tasks.
Jacob Jedryszek
  • 6,365
  • 10
  • 34
  • 39

1 Answers1

1

Try setting the dest directory to the same as the src:

gulp.src('./**/*')
  .pipe(something)
  .pipe(or)
  .pipe(other)
  .pipe(gulp.dest('./'));
Brett DeWoody
  • 59,771
  • 29
  • 135
  • 184