Example 2 Given that the line $l$ passing through point $P(1,2)$ intersects the positive half-axes of the $x$-axis and $y$-axis at points $A, B$ respectively, find the minimum value of $|O A|+|O B|$.
Let the equation of line $l$ be
$$\frac{x}{a}+\frac{y}{b}=1(a>0, b>0),$$

then $\frac{1}{a}+\frac{2}{b}=1$, i.e., $\frac{1^{2}}{a}+\frac{(\sqrt{2})^{2}}{b}=1$.
By Theorem 1, we get
$$|O A|+|O B|=a+b \geqslant(1+\sqrt{2})^{2}=3+2 \sqrt{2}$$