looking over some BB designs in ww2 you'll notice that several were designed not in the ab/xy forward and aft configuration but in a very unique ab(x) all forward.
namely the hms Nelson and Dunkerque of the French Navy but also paper ships with the ijn izumo and apparently the Russian navy Lenin classes.
what made naval designers consider this design? what were the drawbacks and advantages?
The Washington Naval Treaty played a huge part. In brief, the Washington Naval Treaty was supposed to stop the naval arms race by allocating certain limits on the navies of the great powers. Taking into account the relative interests of the participating powers with respect to one another, the treaty aimed at setting limits that would create a relative parity between naval powers. Highlights included
To understand how this impacted battleships, we need to understand battleship armor philosophy of the time. By the end of WW1, the philosophy for armoring battleships was converging on the "all or nothing" concept. The idea here was that intermediate amounts of armor weren't going to provide any useful protection against the large-caliber battleship shells as battleships transitioned away from mixed calibers and towards an all-big-gun arrangement. Meaningful protection against large-caliber shells was possible, but not over the entire ship, so vital areas like the turrets, magazines, engines, and conning tower were prioritized. Following this philosophy, the larger the spacing between turrets, the more area that needs to be armored, as magazines are now further apart. Therefore, an easy way to reduce the weight of armor (or free up weight for thicker armor) is to place the turrets as close as possible, even if that means you've got nothing aft of the superstructure. The British had recognized this and were looking at a no-guns-aft concept before the Washington Naval Treaty was a thing in the form of the N3 battleship and G3 battlecruiser. While neither of those designs went to the extremes of the Nelson class, they had no aft-facing turrets - the aftmost turret was placed in the middle of the superstructure.
The French all-forward ships followed a similar design philosophy in order to get the most of their weight, but they went a step further in the design of their turrets. Turrets are very heavy, so consolidating turrets while keeping the same number of guns can save a lot of weight in armor, ammunition elevators, and turret mechanisms. Two four-gun turrets allowed the French to keep the armored section fairly small, with the big tradeoff being the vulnerability of the ship to turret damage - a single turret knocked out puts half the ship's firepower out of action. The solution here was to put armor plating between pairs of guns, so that a direct hit on a turret would only take out two rather than four guns.
While not having a field of fire directly aft seems like a major issue, it wasn't too much of a concern in reality. Battleships and cruisers operationally engaged from broadsides rather than directly forward or aft, and the turrets still had a reasonably wide field of fire even with the blind spot to the aft. The biggest problems in the Nelson's case were propulsion related. The powerplants were underpowered for the ship's size to save weight, and two rather than four propellers were used. Plus, the far-aft location of the superstructure made it liable to catch heavy winds and make maneuvering more difficult.
AB (the Dunkerques and the Richelius) battleships and the ABC (Nelsons) battleships come about largely as a result of the Washington Naval Conference of 1922 between the United States, the United Kingdom, Italy, France, and Japan. Amongst other things, the Treaty put a hard limit on capital ship tonnage - countries could only have a set total tonnage of capital ships (battleships and battlecruisers) and aircraft carriers. It also limited capital ship displacement - no new capital ship could be more than 35,000 tons standard displacement or have guns larger than 16-inches.
The treaty also set ratios for how much tonnage each power could have. The United States, the United Kingdom, and Japan were limited to respective tonnage ratios of 5:5:3. So, Japan got only 60% of the tonnage of the other powers, something Japanese militarists were rather sore about and would later use to build anti-Western antagonism. How Japanese negotiators were talked into this is much longer story (for one, the Americans were reading Japanese diplomatic codes).
Of course everyone bent the rules or cheated on the tonnage rules in their new designs, but there was only so far the rules could be bent with everyone still keeping a straight face. That left designers trying to meet a demanding slate of requirements with relatively "little" ships.