Closed svi3c closed 9 years ago
Hello,
I just encountered a problem trying to test litcoffee modules.
The problem is a combination of three issues:
The coffee build transformer is registered by default in lib/sandboxed_module.js:10 and you cannot deregister it:
lib/sandboxed_module.js:10
var registeredBuiltInSourceTransformers = ['coffee'];
In lib/sandboxed_module.js:310 the expression
lib/sandboxed_module.js:310
this.filename.search('.coffee$')
also matches .litcoffee files.
So I see three possible ways to get around the problem:
String.prototype.indexOf()
String.prototype.search()
.
Of those you mention, 2 sounds good no matter what. We should probably also do a 3.0.0 release that stops enabling coffee by default.
Hello,
I just encountered a problem trying to test litcoffee modules.
The problem is a combination of three issues:
The coffee build transformer is registered by default in
lib/sandboxed_module.js:10
and you cannot deregister it:In
lib/sandboxed_module.js:310
the expressionalso matches .litcoffee files.
So I see three possible ways to get around the problem:
String.prototype.indexOf()
instead ofString.prototype.search()
or escape the.
at the beginning of the expression