For a 2d flow, for example, the (total) enstrophy is a surface integral over the whole domain, not a line integral (and for a $D$-dimensional flow, it is $\int_{\mathcal{D} \subset \mathbb{R}^D} |\vec{\omega}|^2 ext{d}^{D} x$), with $\vec{\omega}$ the vorticity). (We could also consider the local enstrophy $|\vec{\omega}|^2$ ...)