As said already, outfitting a ship for a purpose is a game loop in itself. A very fun one. Personally, I get very giddy and excited when I decide to build a new ship, and enjoy the hours it takes to plan it, buy and engineer all the modules and assemble it.
And the widely accepted way to play the game is not stripping your ship and re-outfitting it every time you switch activities. If we assume that you do have the modules you need in stock anyway and don't start from scratch every time because you sell off your modules when you switch outfits, there is very little reason to not just have another hull to put your modules on.
You don't even need a lot of different ships; out of the 33 ship hulls I own I really only regularly use nine of them: Two explorers (a Dolphin and a Beluga), one science ship (Phantom), two bounty hunters / CZ ships (Krait II and a Frag Mamba), one AX ship (another Krait II), one Odyssey mission runner (Viper IV), and I also own two Pythons (one miner and one EVAC) that I use very little these days. I haven't hauled for ages, so I don't have a dedicated hauler anymore. Credits are not really an issue, any of the current activity loops makes you enough to buy any hull you want. Except for the BH Krait, where I switch the weapon load out depending on my mood, none of these ships get modified anymore.
That said, I do borrow modules from other ships if I want to test a build and not commit to it. But if the build stays, I put the modules back where they belong and get new ones.