In the film's novelisation, it's made a little clearer that a large amount of the munitions that Batman fired weren't aimed at the Joker at all, they were aimed at the floats and anything else that looked hinky. Only the bullets seem to have been targeted at him, and they were evidently evaded by his erratic dancing:
Bullets, lasers, and missiles screamed down on Broad Avenue, all
taking out their assigned targets. Batman wanted to make sure the
Joker didn’t have any more surprises hiding in any of his floats or
other equipment. So the equipment had to be obliterated.
In the middle of all the destruction, he saw the Joker doing the
waltz. Everything had missed him. So far.
All right! He was having fun now.
Things were exploding all over the place. There went a float, here a
truck—oops! a building got it that time — bad shot.
The 1988 version script simply hand-waves his survival as nothing short of miraculous
Batman OPENS UP with everything, and we see the GATLING, MISSILES and
LASER EXPLODE INTO ACTION.
EXT. ANGLE ON JOKER - MOMENT LATER
A rocket, bullets, and the laser beam SMASH into the street, all
around the Joker. He leaps, LAUGHING, into the air and, miraculously,
avoids being hit.
As an aside, it's worth noting that in the original (1986 version) script, the Joker was in a tank during this sequence.
EXT. BROAD AVENUE - ON BATWING
The black ultralight hurtles down Broad Avenue at full speed, on a
suicide mission. MISSILES streak past on either side. MACHINE GUN
FIRE peppers the dome of the cockpit. The REAR STABILIZER WING takes
a direct hit... and BURSTS INTO FLAME!
The BATWING, trailing thick black smoke, bears down on the tank like
a kamikaze plane. BOMB BAYS OPEN as BATMAN dumps the last of his high
explosives DIRECTLY INTO THE PATH OF THE TANK. The BATWING takes a
hard bounce off the top of the tank and CRASHES TO THE STREET.