Official solution
f(x)= \[-2 \& -2\le x\le 0 \ x-2 \& 0\]
\[\begin{gathered} h(x)= -x-2+2=-x -2\le x\le 0 \\ 0 0<x\le 2 \\ \therefore \int _{-2}^{2}h(x)dx=\int _{-2}^{0}-xdx+\int _{0}^{2}0dx \\ {\frac{{x}^{2}}{2}|}_{0}^{-2}=\frac{4}{2}=2 \end{gathered}\]