I can't see why the following could not be a counterexample.
Let $f:[-1;1]\to\mathbb{R}$ defined as $f(x) = \sqrt[3]{x}$. It's a continuous function that goes from a compact set to $\mathbb{R}$ but it's not uniformly continuous.
I really appreciate any kind of help.