Shadow spiders are not a good monster to train on, but if you want to kill them, your best bet is to just melee them. Another way could be to use the side room in the Waterfall. Try to find a box or any inanimate object to stand behind to range the spiders from.
You need to have finished Waterfall Quest to access the lair of the Shadow spider. You need a rope and Glarial's amulet (obtained from the quest) to access the place. The shadow spiders' attack drains Prayer (50%).