Open parris opened 9 years ago
This comes from regexpu.
@mathiasbynens Any plans to provide an ES6 version?
@arv Unlikely. Providing an ES6 version of regexpu would mean:
Ref. #1295.
@parris As a workaround, you could try adding regexpu as a direct dependency next to Traceur.
I believe this is due to a recent change. If I included traceur from either the npm or bower as a plain script tag at the top of my application everything works fine. I need to reference
window.traceur
to then use it, but everything works. If I instead set up a traceur to load inside or after requirejs then I get the following error:Uncaught Error: ModuleEvaluationError: regenerate is not a function in traceur@0.0.89/src/outputgeneration/regexpuRewritePattern.js
I've tried a few methods to make this work, and I've almost isolated the issue.After scouring the built source code I found this:
line 27132:
and then later (line 28164):
This series of events appears to be result in an anonymous define or at the very least a module that can't be found.
I've created an es6 requirejs loader that nearly works with the latest version of traceur. The es6 module pattern doesn't quite meet the needs of the general web yet and functionally resembles AMD, which is why we are trying to mix the 2 things. This all nearly works. In fact, I'd even be satisfied if traceur just registered globals and didn't try to be overly accommodating for AMD.