Skip to content

Commit 5a31a92

Browse files
Build: compile espree's deps to ES5 when generating site (fixes #11014) (#11015)
Previously, the build process would compile ESLint's dependencies to ES5 when generating a website bundle, but not espree's dependencies. Now that espree has dependencies with ES6 code, it's necessary to also compile espree's dependencies.
1 parent 3943635 commit 5a31a92

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Makefile.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -849,7 +849,7 @@ target.browserify = function() {
849849
exec(`${getBinFile("browserify")} -x espree ${TEMP_DIR}linter.js -o ${BUILD_DIR}eslint.js -s eslint --global-transform [ babelify --presets [ es2015 ] ]`);
850850

851851
// 6. Browserify espree
852-
exec(`${getBinFile("browserify")} -r espree -o ${TEMP_DIR}espree.js`);
852+
exec(`${getBinFile("browserify")} -r espree -o ${TEMP_DIR}espree.js --global-transform [ babelify --presets [ es2015 ] ]`);
853853

854854
// 7. Concatenate Babel polyfill, Espree, and ESLint files together
855855
cat("./node_modules/babel-polyfill/dist/polyfill.js", `${TEMP_DIR}espree.js`, `${BUILD_DIR}eslint.js`).to(`${BUILD_DIR}eslint.js`);

0 commit comments

Comments
 (0)