Someone has to help market those products. Someone has to stock the goods and keep track of them. Someone has to introduce new products and train installers in their use. Someone has to recommend which products to use to customers who are unsure or don't care. Someone has to invest a ton of money in huge buildings, equipment and vehicles for these functions to get fulfilled.
Someone has to employ the people who know how to get it all done.
None of these tasks has to be done by a bona fide wholesaler. Anyone can do it - manufacturers, their reps, contractors, retailers. Some of them have tried it. A tiny percentage of them have even made it work, more or less. But none of them has really eliminated the wholesaler.