This uses class properties to bind the function to scope. It seems that when generating the tcomb assertion it generates:
_this.handleDeckClassChanged = function (_ref2) {
var body = _ref2.body;
var article = _ref2.article;
_assert(_arguments[0], PresenterObject, "{ body, article }");
var ret = function (_ref3) {
var body = _ref3.body;
var article = _ref3.article;
_this.props.signals.slides.bodyModeChanged({ body: body, article: article });
}.call(_this2, {
body: body,
article: article
});
_assert(ret, _t.Nil, "return value");
return ret;
}, _temp), _possibleConstructorReturn(_this, _ret);
}
Where _assert(_arguments[0], PresenterObject, "{ body, article }"); is using arguments from outside of the function rather than directly using _ref2 or even just arguments[0]
I have the following code:
This uses class properties to bind the function to scope. It seems that when generating the tcomb assertion it generates:
Where
_assert(_arguments[0], PresenterObject, "{ body, article }");
is using arguments from outside of the function rather than directly using_ref2
or even justarguments[0]
This means my assertion always fails.