Adjust oven rack to middle position and preheat the oven to 400°F (200ºC).
Cut the onion into eighths, separating the layers to create wide, square slices. In a medium sauté pan, heat 1 tablespoon of the oil over low heat, about 5 minutes. Add the onion, season with salt and pepper, and sauté, stirring occasionally, until the onion has wilted and started to turn translucent, 8 to 10 minutes; be careful not to let it brown. Add the red wine vinegar to the pan and shake briefly to coat onions, then transfer onion mixture to the bottom of an 8- by 12.25-inch baking dish.
Wipe the pan with a paper towel to clean it, then place it back over low heat and add the remaining 1 tablespoon of oil; heat until shimmering, about 5 minutes. Add the anchovy paste and, using a wooden spoon, stir to dissolve the paste into the oil, about 1 minute. Dump the breadcrumbs into the pan and stir to completely coat them with the oil, about 15 seconds. Transfer the breadcrumbs to a small bowl to cool slightly, about 5 minutes.
Add herbs to the bowl with breadcrumbs, season with salt and pepper, and stir to combine.
Lay the fish on top of the onions and season fish with salt and pepper. Distribute the breadcrumb-herb mixture evenly on top of the fish. Add the white wine or water to the pan and scatter the olives around the dish.
Bake the fish until opaque and flaky but still moist, 15 to 20 minutes; check the pan after 10 minutes and add a bit more water or wine if dry.
Serve immediately, with onions, olives and pan juices spooned alongside the fish.
