“On the way” (途中) is a very useful expression in English.
“Drop by / Stop by” (寄る) is also a common expression. “Drop by” is a little more casual. However they both have the same meaning. So it is okay to use both of them to your friends. Stop by is a little more formal(公式).
While I was on my way home yesterday I stopped in Maizuru Park. I wanted to see the cherry blossom trees.
The trees have not bloomed yet. The flower buds(花芽)are not open. I am excited to see the cherry blossoms this year.
I will often drop by the park on my way home to check when the buds start to open.