The idea of a shutoff is to stop the flow of water quickly and easily. In an emergency, I would hate to have to wiggle out the machine with water flailing. If you do put them in the cabinet, push them towards the rear.
Like six, I can't comment on code. But I will say probably not best practice. The cupboard WILL become full of cleaning and laundry products, still blocking the shut-offs. Although not as bad as behind the machine.My initial plan was to install the shutoff in a laundry outlet box in the rear wall, then add a cutout in the cabinet when I install.
My concern was more if it was a code violation or not a best practice to install inside of a cabinet.
Why not have the bottom of the cabinet higher up or build the cabinet around the hoses and water supply leaving them exposed on the wall?
I have never heard this before. F'real?Are you referring to the shut-offs for the washing machine hoses? You would want those easily accessible, not hidden, so they can be turned off preferably after every laundry session. This is even recommended by the machine and the hose manufacturers.