You can define the delta function, as folows:
Define
$$
\delta_a(x) =
\begin{cases}
1/a & |x|\leq a/2\\
0 & \text{otherwise.}
\end{cases}
$$
So we see that this function defines a box of width $a$ and height $1/a$, so that
$$
\int_{\mathbb{R}} \delta_a(x)\;dx=1,\quad\forall a\in\mathbb{R}_{>0}.
$$
We can now think of taking the limit as $a\to0⁺$, whereas our box tends to something infinitely thin and infinitely tall but still with total area $1$. In that case we also have
$$
\lim_{a\to\,0⁺}\delta_a(x) = 0, \quad\forall x\neq0.
$$
Let's take the condition
$$
\int_{\mathbb{R}} \delta(x)f(x)\;dx = f(0)
$$
as the definition of the delta function, and let's see whether $\lim_{a\to0⁺}\delta_a(x)=\delta(x)$. For any (integrable) $f$ we have
$$
\int_{-\infty}^\infty \delta_a(x)f(x)\;dx=\int_{-a/2}^{a/2} \delta_a(x)f(x)\;dx=\frac{1}{a}\int_{-a/2}^{a/2} f(x)\;dx,
$$
Where we have used that $\delta_a(x)=1/a$ on $[-a/2,a/2]$ and $0$ elsewhere.
Now by the mean-value theorem we have that there exists a number $\mu(a)\in[-a/2,a/2]$, such that $f(\mu(a))$ is the mean-value of $f$ on $[-a/2,a/2]$. The result is that we can write
$$
\int_{-a/2}^{a/2} f(x)\;dx=f\big(\mu(a)\big)\int_{-a/2}^{a/2}dx= af\big(\mu(a)\big),
$$
which in turn gives us
$$
\int_{-\infty}^\infty \delta_a(x)f(x)\;dx=f\big(\mu(a)\big).
$$
Taking the limit as $a\to0⁺$, we see that $\mu(a)$, being confined to the interval $[-a/2,a/2]$, which tends to the singleton $\{0\}$ as $a$ tends to $0⁺$, must also go to $0$, and hence, assuming continuity of $f$, we have
$$
\int_{-\infty}^\infty \lim_{a\to\,0⁺}\,\delta_a(x)f(x)\;dx=\lim_{a\to\,0⁺}\int_{-\infty}^\infty \delta_a(x)f(x)\;dx=\lim_{a\to0⁺}f\big(\mu(a)\big)=f(0).
$$
As desired.