ε-δ definition:
$(\forall \epsilon >0) \ (\exists \delta >0)(\forall x \in D) (0 < \lvert x - a \rvert < \delta \Rightarrow \lvert f(x) - L \rvert < \epsilon)$
I don't understand why in the epsilon-delta limit definition x is defined as being x∈D instead of just using x∈ $\mathbb{R}$. Would specific issues arise for certain functions or types of functions if I were to use x∈ $\mathbb{R}$ instead?
I think that $D$ is the domain of the function. Take for example the function $f(x)=\ln(x)$.
You know that this function is a map between $\underbrace{(0,\infty)}_D\to\mathbb R$, so in this case it does not make sense to study continuity at a point $x = -2$ ,for example, as this function is not defined here. If you have a function $f: \mathbb R \to \mathbb R$, for example $f(x)=x$, then your $D = \mathbb R$ and then you can let $x \in \mathbb R$.