The restriction of $f$ to the boundary has degree zero. It is true also in higher dimensions.

> **Theorem.** If $f\in W^{1,n}(B^n,S^{n-1})$ and $f|_{\partial B^n}\in C^0$, then $f|_{\partial B^n}:S^{n-1}\to S^{n-1}$ has degree zero.

Here the restriction to the boundary $f|_{\partial B^n}$ is defined as a trace of a $W^{1,n}$ function.

**Proof.** In fact the mapping $f$ takes values into $\mathbb{R}^{n}$ since $f:B^n\to S^{n-1}\subset\mathbb{R}^n$. Given $\epsilon>0$ define
$r_{\epsilon,x}=\epsilon(1-|x|)$ and 
$$
f_\epsilon(x)=\frac{1}{|B(x,r_{\epsilon,x})|}\int_{B(x,r_{\epsilon,x})} f(y)\, dy.
$$
That is we average $f$ over a ball of radius $\epsilon$ times the distance of $x$ to the boundary of the unit ball $B^n$. 
The function $f_\epsilon$ is continuous. As $x$ approaches $\partial B^n$, the radius of the ball over which we average tends to zero and hence $f$ is continuous up to the boundary, because $f_\epsilon$ is a formula for the extension of the trace of the function, see [1], 
$f_\epsilon|_{\partial B^n}=f|_{\partial B^n}$.

According to the Poincare inequality
$$
\left(\frac{1}{|B(x,r_{\epsilon,x})|}\int_{B(x,r_{\epsilon,x})}|f(y)-f_\epsilon(x)|^n\, dy\right)^{1/n}
\leq C\left(\int_{B(x,r_{\epsilon,x})}|\nabla f|^n\right)^{1/n}.
$$ 
Since
$$
\operatorname{dist}(f_\epsilon(x),S^{n-1})\leq |f(y)-f_\epsilon(x)|
\quad
\text{for all $y$}
$$
we have
$$
\operatorname{dist}(f_\epsilon(x),S^{n-1})\leq
C\left(\int_{B(x,r_{\epsilon,x})}|\nabla f|^n\right)^{1/n}.
$$
The right hand side converges uniformly to $0$ in $x$. That is if $\epsilon$ is small enough, $f_\epsilon(x)\neq 0$ and hence
$$
g(x)=\frac{f_\epsilon(x)}{|f_\epsilon(x)|}
$$
is a continuous map $g:B\to S^{n-1}$, 
$g|_{\partial B^n}=f_\epsilon|_{\partial B^n}=f|_{\partial B^n}$. This shows that $\operatorname{deg}(f|_{\partial B^n})=0$.

[1]  **G. Leoni**, *A first course in Sobolev spaces. Second edition*. Graduate Studies in Mathematics, 181. American Mathematical Society, Providence, RI, 2017.

**Remark.** Later I will add more relevant references since the trick with the Poincare inequality used above, is due to Schoen and Uhlenbeck.