I went to replace an outlet in my garage. Opened it up. The hot and neutral wires were just straight through the box. In through the top and out the bottom in one solid piece of wire each. A portion in the middle had been stripped and looped around the screws.
I don’t *think *it’s actually against code (not an electrician,) just kind of lazy and not really the best practice provided that strain relief and everything else is done properly. Electrically it should be pretty much exactly the same as doing it the normal way.
I encountered it on one light switch in my house when I was replacing it. I really didn’t feel like running out to the hardware store to buy another couple of inches of wire to redo it, so somewhat to my shame I just hooked up the new switch the same way.