I've come across this pattern:
(0, _inherits3.default)(SpecRunner, _File);
I can't completely wrap my mind around it -- to me it looks like the comma operator is being used, which would evalute the expressions inside the first pair of parentheses from left to right and return the last expression, in this case inherits3.default
. In case this is a callable, it would call it with the arguments SpecRunner
and _File
.
Is my analysis correct and if so, why would someone, instead of writing,
_inherits3.default(SpecRunner, _File);
use such a pattern?