A simple way to log javascript errors.