Docks are one of my favorite pieces of cover to fish, because they ALWAYS hold fish. Not every dock, but if there's docks on a lake with bass in it, somewhere, there's a dock with fish under it. Another thing I like about dock fishing is how I can almost always pattern the fish when they're under the docks. There's several little lakes near me with lots of docks, and then the dock fishing capital of the midwest is only a few hours drive (LOZ). There's lots of different kinds of docks; wooden docks, plastic docks, concrete docks, metal docks, floating docks, anchored docks, docks with foam floats, plastic floats, or metal floats. There's docks with wood pillars, concrete pillars, and metal pillars. There's docks with cables, docks with ladders, docks with lifts, docks with boats, docks with rod holders, docks with hanging walkways, floating walkways, just a ton of variables and it can get overwhelming.
One of my first things that I think is one of the most difficult parts, pretend the docks aren't there. Look at a map, find the places the fish want to be even without the docks. The docks that sit on those places are going to be your high percentage docks, the ones that hold the most and biggest fish, the most often at that time. Then you have to fish those docks thoroughly to try to get a few bites to figure out what the fish are doing. When you get a bite, pay attention. Those bites are the fish talking to you, telling you what you need to know to have a successful day on the water.
I like to fish docks with several types of baits but I will always have a skirted jig, a stickworm either wacky or T rigged weightless, a shakyhead, a bladed jig and/or spinnerbait, a buzzbait, and a swimbait. The jig is usually my primary attack bait because I can put it almost anywhere and I can fish it anywhere in the water column. The shakyhead will be to dissect the dock further if I get a few bites and want to see if there's more fish that are just too finicky to eat the jig. The stickworm is skipped under walkways, docks floats, boats, and pitched to potential holding areas like dock post, swim ladders, and crossbars. The bladed jig, buzzbait, and swimbait are all fished similarly, along the edges of docks and inside dock stalls, especially around floating docks and extra bonus points if there's shad, gills, or other baitfish seen around the underside of the docks floats.
Once I get a bite and pick the dock apart, I'll fish the adjacent docks and see if fish are holding on nearby docks or just that one. I also make note of where on the dock the fish were holding, and if they were holding on a piece of cover, on the bottom, up high under the floats or walkway, ect. Then it's a matter of finding and fishing similar docks to find out if I've discovered a pattern, or if I just crossed paths with a random fish and still have work to do. Docks with rod holders mounted on them and fish baskets or minnow buckets in the water are often worth fishing because those items are a sign of crappie fishermen, who often place brushpiles in the lake, and those brushpiles will also hold bass along with the crappie.
One of my favorite local lakes to dock fish is very patternable. Often times, I'll have to drag a jig slowly and the fish will be on the outside corners of the docks. I've also had times on that lake that I had to cast to the front and center of the docks and the bass were there on the first couple movements of the bait. Sometimes they want a stick bait skipped under the docks (usually a technique for bigger smallmouth). I've had a couple trips there that the bigger fish were on the ladders. One that stands out was when they were on the ladders but wouldn't bite my normal presentations. It was during the spawn when the fry had hatched recently and we could see large fish guarding fry near the dock ladders, but they wouldn't bite anything we offered. We had all but given up when my buddy tried a Ned rig pitched directly into the ball of fry by a ladder. His line sank a foot and stopped. We ended up with over 80 fish and badly outfished the other boat on the lake that tried to force the normal baits on the fish but never got them to eat.
So if you make sure to really pay attention to details and focus on what they are trying to tell you, it will make you a much better dock fisherman. Once you figure it out, it's really a great feeling.
First place at Grand Lake, fish were positioned behind the docks along the cables and the bait had to be drug along the bottom very slowly. This was a time they were also very color specific (had to be purple somewhere in the bait).
Fish were positioned on the north (sunny side, early spring), deepest corner of shallow docks with metal poles.
Holding on the dock ladders on shallow docks, 3 docks in a row.
The Ned rig/dock ladder/fry trip.