I am trying to setup my google-closure-compiler to be able to read my files which uses Node core modules and I read online that I need the NodeJS externs... I downloaded a set of externs from: https://github.com/dcodeIO/node.js-closure-compiler-externs (which is like 2 years old??) and then in the compiler option I added the following in my gulpfile.js:
process_common_js_modules: true,
externs: '../node.js-closure-compiler-externs/fs.js',
When running gulp I get:
[19:38:07] gulp-google-closure-compiler: /src/js/myfile.js:3: ERROR - Failed to load module "fs"
const fs = require('fs');
What is really the right way to setup a JavaScript project that uses Node.js and have google-closure-compiler regconize things properly? Is there a step by step tutorial somewhere?