Some trial and error yielded a few pretty good results. I experimented with different stops from f22 down to f5.6. I settled for f8. Timing for holding the shutter open is critical. I used my cable release on Bulb. Too short and you don’t get any trails. Too long and the fireworks explode over each other and you get a mess. Most shots were about 4 seconds.
D3s 16-25 Nikkor