What you write is more or less true. First note that it is not enough to assume that $f(x,t)$ is differentiable at $x_0$ (for (almost) all $t$), we need that there is a neighorhood $(x_0 - \varepsilon, x_0 + \varepsilon) =:I$ such that $f(\cdot, t)$ is differentiable in $x$ for all $x \in I$ and (almost) all $t \in A$, where the "exceptional null set" must not depend on $x$.
The assumption $|\partial f/\partial x (x,t)| \leq g(x)$ only makes sense in this setting, otherwise we could only require $x_0$ instead of $x$ and the proof also needs this assumption (see below).
Now, let $h_n \to 0$ with $h_n \neq 0$ for all $n$ and w.l.o.g. with $x_0 + h_n \in I$ for all $n$. Let
$$
F(x) := \int_A f(x,t) \, dt \text{ for } x \in I,\\
G(x) := \int_A \frac{\partial f}{\partial x}(x,t) \, dt \text{ for } x \in I.
$$
Here, the integral defining $F$ is interpreted as an improper Riemann integral (it is possible that this integral does not exist as a Lebesgue integral), but the integral defining $G$ is interpreted as a Lebesgue integral. If $t \mapsto \frac{\partial f}{\partial x}$ is Riemann integrable over every compact subinterval of $A$ (for example, if it is continuous in $t$), then it can also be interpreted as an improper Riemann integral, at least if we assume that the dominating function $g$ is (improper) Riemann integrable.
Observe that the assumptions guarantee that $F,G$ are well-defined. Measurability of $t \mapsto \frac{\partial f}{\partial x}(x,t)$ for each $x \in I$ is implied by the pointwise convergence $$\frac{\partial f}{\partial x}(x,t) = \lim_n \frac{f(x+h_n, t) - f(x,t)}{h_n},
$$
which will also be employed below.
We now have
\begin{eqnarray*}
\left|\frac{F\left(x_{0}+h_{n}\right)-F\left(x_{0}\right)}{h_{n}}-G\left(x_{0}\right)\right| & = & \left|\int_{A}\frac{f\left(x_{0}+h_{n},t\right)-f\left(x_{0},t\right)}{h_{n}}-\frac{\partial f}{\partial x}\left(x_{0},t\right)\,{\rm d}t\right|\\
& \leq & \int_{A}\left|\frac{f\left(x_{0}+h_{n},t\right)-f\left(x_{0},t\right)}{h_{n}}-\frac{\partial f}{\partial x}\left(x_{0},t\right)\right|\,{\rm d}t.
\end{eqnarray*}
Note that the integrands are measurable and that for (almost) all $t \in A$, the mean value theorem yields some $\xi_{n,t} \in I$ (even between $x_0$ and $x_0 +h_n$) such that
$$
\left|\frac{f\left(x_{0}+h_{n},t\right)-f\left(x_{0},t\right)}{h_{n}}\right|=\left|\frac{\partial f}{\partial x}\left(\xi_{n,t},t\right)\right|\leq g\left(t\right).
$$
This shows that the integrands in the integrals are Lebesgue-integrable and dominated by an integrable function. As the integrand in the last integral converges pointwise to $0$ for $n \to \infty$, the dominated convergence theorem yields
$$
\left|\frac{F\left(x_{0}+h_{n}\right)-F\left(x_{0}\right)}{h_{n}}-G\left(x_{0}\right)\right| \to 0,
$$
so that $F$ is differentiable (in $x_0$) with the expected derivative.
Differentiation under integral signs, better known as the Feynman’s trick, is not a standard integration technique taught in curriculum calculus. Nevertheless, it is widely utilized outside classrooms and may appear somewhat magic to those seeing it the first time.
Despite the mystique around it, it is actually rooted in double integrals. A bare-bone illustrative example is
$$I=\int_0^1\int_0^1 x^t dt \>dx= \ln2$$
The natural approach is to integrate $x$ first and then $t$. But, an unsuspecting person may integrate $t$ first and then encounter
$$I=\int_0^1\frac{x-1}{\ln x} dx$$
Now, he/she is stuck since there is not easy way out. Fortunately, there is, which is to differentiate $J(t)$ below under the integral, i.e.
$$J(t)=\int_0^1\frac{x^t-1}{\ln x} dx,\>\>J(t)' = \int_0^1 x^t dx= \frac{1}{1+t}
\implies I=\int_0^1 J(t)'dt=\ln 2$$
A knowledgeable math person, aware of its double-integral origin, would just undo the $t$-integral to reintroduce the double form, and then integrate in the right order,
$$I=\int_0^1\frac{x-1}{\ln x} dx=\int_0^1\int_0^1 x^t dt dx = \int_0^1 \frac1{t+1}dt= \ln 2$$
The two approaches are in fact equivalent, with the double-integrals actually more straightforward. The Feynman’s trick is appealing, since it ‘decouples’ a double-integral in appearance, especially when the embedded double-integral is not immediately discernible. When a seemingly difficult integral is encountered, the differentiation trick is often employed to transform the original integrand to a manageable one.
As a practical example, the trick can be used for deriving the well-known integral
$$I=\int_0^\infty \frac{\sin x}x dx=\frac\pi2$$
with $J(t)=\int_0^\infty \frac{\sin x}x e^{-tx}dx$, $
J’(t)=-\frac{1}{1+t^2}$ and $I=- \int_0^\infty J’(t)dt$.
Best Answer
Notice that $$u(x+te_i )-u(x)=\int_{B(0,r)}(\frac{r^2 -\vert x+te_i \vert^2 }{n\alpha (n)r\vert x+te_i -y\vert^n }-\frac{r^2 -\vert x\vert^2}{n\alpha(n)r\vert x-y\vert^n})g(y)\mathrm{d} S(y)$$thus when we do the differentiation, if we let $t$ sufficiently small, we can state that the term in the parenthesis is bounded and exchange the limit and the integral.