failure to match srcModuleRegex
leads to null
instead of __require__
in bundle
#113
Labels
srcModuleRegex
leads to null
instead of __require__
in bundle
#113
I'm not at all sure that this is really a bug, i'm just posting an issue so that you can consider whether it's desired behaviour.
Situation: if you have a PureScript file in which the
module
statement isn't the very first thing in the file then the regex defined inpurs-module-map.js
will fail and you'll get anull
instead of the desired__require__
for the compiled JavaScript that you need in the Webpack bundle. In my case, i discovered that i'd acquired a space in front of the module name at some point.i'm sure there are many things that could break the regex (tho probably almost all others would be caught by the compiler failing to compile the file) so it seems to me that possibly the fix, if a fix is needed, would be to raise an error whenever there isn't a match.
The text was updated successfully, but these errors were encountered: