Derivation (isometries are homeomorphisms)
Suppose $f: (X,d) \to (Y,d')$ is an isometry. Then $f$ is bijective.
For all $x_0 \in X$ and $\epsilon>0$, if $x\in B_\epsilon(x_0)$, then $$ \begin{align*} d'(f(x), f(x_0)) = d(x,x_0) < \epsilon \end{align*} $$ so $f(x) \in B_\epsilon(f(x_0))$. Hence $f$ is continuous. Apply the same argument to $f\inv$.