babel / babel/gulp-babel

*.js files out of the root directory cannot be compiled

Open
#180 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
1.3k
Forks
113
PR merge metrics
No merged PRs in 30d

Description

gulpfile.js and other files are put in “tools” directory. Now I compile *.js under “builds” directory that is the same level as “tools” directory, but the compilation does not work.

// tools/gulpfile.js
```js
// doesn't work
gulp.task('test', function () {
gulp.src("../builds/*.js")
.pipe(babel())
.pipe(gulp.dest('../builds'));
})

// work
gulp.task('test', function () {
gulp.src("./*.js")
.pipe(babel())
.pipe(gulp.dest('./'));
})
```

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with tools/gulpfile.js and reproduce the failing gulp.src("../builds/*.js") case against the sibling builds directory, then compare it with the working root-level glob. Trace how the plugin handles the source and destination paths and verify the fix by confirming that builds/*.js is compiled successfully.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
build-system
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.