Often while solving an equation of the form $$ f(y) \frac{dy}{dx} = g(x) $$ we integrate on both sides to obtain $$ \int f(y) \frac{dy}{dx} \, dx = \int g(x) \, dx. $$ We normally write it as $$ \int f(y) \, dy = \int g(x) \, dx. $$ But I don't understand how we replace $ \int f(y) \frac{dy}{dx} \, dx $ with $ \int f(y) \, dy $ on the LHS.
Is there a way to show that $$ \int f(y) \frac{dy}{dx} \, dx = \int f(y) \, dy $$