This is a very interesting question and one that points out how special holomorphic functions are! I don't know if the following is a complete answer, but let me adress some points:
1) The interpretation of "area under the function along a path" might be a little bit problematic in this case because the function takes complex values. However I think this is a minor issue: One could maybe split the integral into real and imaginary parts and thus consider two line integrals or use the interpretation of a line integral of a vector field as measuring the angle between the curve and the values of the function and again obtaining a line integral. Also this question and its answer might be interesting in that respect
2) A holomorphic function on a simply connected domain always has an antidervative and as such, a line integral is nothing but the value of this antiderivative at the endpoint of the line minus the value at the start. But if these two points are the same, the values are as well and so the value of the integral is zero!
3) The functions $f(z)=z^{-n}$ for $n>0$ are holomorphic on $\mathbb{C}\backslash \{0\}$ which is not simply connected. However, for $n\neq 1$ they still have an antiderivative holomorphic everyhwere except the origin (namely $\frac{z^{-n+1}}{-n+1}$).
4) The function $\frac{1}{z}$ "has" $\operatorname{log}z$ as antiderivative, however this is not defined on the complex plane without one point. It is almost, however: If we remove one ray "from the origin to infinity" from our plan, we can define it. However this ray will cut our closed loop. Assume that it does so in the starting point. We then have to approach it from two sides. It turnes out that the value of the logarithm "on" the ray (where it is not defined) differs exactly by $2\pi i$, depending on the direction we come from. This can be made precise in different ways: Formally compute the limits or use the idea of a "covering Riemann surface" where the logarithm is defined and lift the path to this Riemann surface. There it is no longer closed but it "winds up the staircase" once. (This last idea needs some time to make precise, so I refer to the Wikipedia article which has for example a nice picture of the "staircase")
5) For a general meromorphic function use a series representation as shown in the other answer. All terms of the series except the one having the residue as coefficient have holomorphic antiderivatives so they do not contribute to the line integral.