Pre-paint all the pieces before building the closet shelves to make touch-ups easier with fewer coats to build up at the end ... you a place to screw into the wall studs and give the structure ...