Closed DigitalFlow closed 7 years ago
See https://github.com/nikku/karma-browserify#transforms
Use {global: true}
, not a karma-browserify thing, it's just passed along to browserify and handled there.
Hey @bendrucker,
thanks for your answer.
For anyone having the same issue in the future, this is what worked for me:
browserify: {
debug: true,
transform: [ ['brfs', {global: true}], istanbul({
ignore: ['**/node_modules/**', '**/spec/**']
})]
}
FYI that's not subargs, this is:
browserify -t [ foo --bar=555 ] main.js
Sorry, you're right. Fixed it.
Hey everyone,
thanks for this framework, it helped me making a huge step forward for my project quality.
There's one thing that I can't find out how to configure: I have some transitive dependencies (I don't require them, but my dependencies do), which have fs.readFileSync calls in them. So to get rid of them, I run brfs on it.
In my package.json, my task looks as follows:
I have to use the -g flag for my transform, otherwise brfs would not be executed on my transitive dependencies.
In my karma.conf.js I have the following browserify configuration right now:
This however behaves just like the "normal" transform, so my transitive dependencies are not transformed like this. I read that you can pass browserify options just like the "debug" option above, but I did not succeed on doing this for the -g / --global-transform=MODULE option.
Any help on this would be greatly appreciated.
Kind Regards, Florian