Amazingly, there is this nifty thing called a “port” that allows a mouse to be plugged into a laptop. It is pretty incredible technology. /s
I tend to vacillate myself depending on the noise of the environment vs the work at hand. If I need to spread out across a few monitors, dock it. If I just need to do some simple paperwork, portable. If I want to force no distractions, portable (as it is more difficult to see things when your screen real estate is reduced.)
Helps if you have good eyesight too, laptop UIs today are at clown magnification levels anymore.

IDEs just get worse, bellwether signal for where software companies think software in general is going, if the dev tools are already going to crap.