See my comment in https://github.com/facebook/react/pull/11291#issuecomment-338974574.
I verified https://github.com/facebook/react/pull/11291 introduced this regression.
var condition = node.arguments[0];
            var errorMsgLiteral = evalToString(node.arguments[1]);
            var devInvariant = t.callExpression(
              node.callee,
              [
                t.booleanLiteral(false),
                t.stringLiteral(errorMsgLiteral),
              ].concat(node.arguments.slice(2))
            );
            devInvariant[SEEN_SYMBOL] = true;
            var localInvariantId = getProdInvariantIdentifier(path, this);
            var prodErrorId = errorMap[errorMsgLiteral];
            var prodInvariant;
            if (prodErrorId === undefined) {