Any Function in $W^{1,p}$, $p>N$, has a continuous representative by the Sobolev embedding theorem so there is no issue here. If $f\in W^{1,N}$, then $f\in W^{1,p}_{\rm loc}$ for ant $1\leq p<N$ so it suffices to discuss the case $1\leq p<N$ only.

The following result is Theorem 1 on p. 160 in [1] (I am referring to the first edition).

> **Theorem.** There is a representative of $f\in W^{1,p}(\Omega)$, $1\leq p<N$, $\Omega\subset\mathbb{R}^N$ that is $p$-quasicontinuous.
> That means for any $\epsilon>0$, there is an open set $V\subset\Omega$ with $\operatorname{Cap}_p(V)<\epsilon$
> such that $f|_{\Omega\setminus V}$ is continuous.

Here by a representative I mean a Borel function defined everywhere and equal to $f$ almost everywhere and $\operatorname{Cap}_p$ stands for the $p$-capacity.

Capacity is a certain outer measure. While I will not recall its definition I will explain how it is related to the Hausdorff measure. The next result is Theorem 4 p. 156 and and Theorem 3 p. 193  in [1].

**Theorem.** If $1\leq p<N$ and $\operatorname{Cap}_p(A)=0$, then $\mathcal{H}^s(A)=0$ for all $s>n-p$. Moreover if $A$ is compact, then $\operatorname{Cap}_1(A)=0$ if and only if $\mathcal{H}^{N-1}(A)=0$.




**[1] L. C. Evans, R. F. Gariepy,** *Measure theory and fine properties of functions.* Studies in Advanced Mathematics. CRC Press, Boca Raton, FL, 1992.