1. Build a square box away from all solid blocks (I did mine on a bridge)
2. Place slabs letting you hit them but blocking 1 block tall mobs from passing
3. Put spawners along the back wall
4. Enchant a stone sword with Smite 5, it does 10 hearts to undead
5.Make sure water pushes to mobs to slabs, but they can't pass
6. Slap away to your heart's content