Closed zakdances closed 8 years ago
@zakdances Hmm. Please provide a simple example that produces the error.
@johnsoftek I couldn't re-create this error. Sorry for wasting your time!
@zakdances @johnsoftek
Do we know what resolved this issue?
I'm trying to create a JSPM plugin using Pug. I'm running into this same issue (see screenshot below).
@coderfin Are you trying to include uglify a Javascript file?
@johnsoftek Yes, it's part of pug/jade
@coderfin pug/jade is written for node.js, so it uses modules and objects that exist in node.js such as fs
and the process
object. So you need to avoid code that uses those features. For example, plugin-jade replaces the built-in include
to bypass the use of fs
.
I assume that you are using include name-of-javascript-file.uglify
. You could extend the include
replacement to recognise .uglify
and invoke a browser friendly uglifyjs - or process as plain js.