spinjs
Version:
[](https://gitter.im/sysgears/spinjs?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [;
var JSRuleFinder_1 = require("./shared/JSRuleFinder");
var FlowRuntimePLugin = (function () {
function FlowRuntimePLugin() {
}
FlowRuntimePLugin.prototype.configure = function (builder, spin) {
var stack = builder.stack;
if (stack.hasAll(['flow-runtime', 'webpack']) && !stack.hasAny('dll')) {
var jsRuleFinder = new JSRuleFinder_1.default(builder);
var jsRule = jsRuleFinder.findAndCreateJSRule();
if (jsRule && !jsRule.use.options.babelrc) {
jsRule.use = spin.merge(jsRule.use, {
options: {
plugins: [
[
'babel-plugin-flow-runtime',
{
assert: true,
annotate: true
}
]
]
}
});
}
}
};
return FlowRuntimePLugin;
}());
exports.default = FlowRuntimePLugin;
//# sourceMappingURL=FlowRuntimePlugin.js.map