Look, this isn't that hard to get right? Slings just aren't a strong enough weapon with a long enough range.
Look, if this isn't a hard thing to get right then why are you so determined to get it wrong?
Slings do not hit as hard as crossbows and no one ever said they did. But if how hard you hit is what you see as important then you just need two slings to match a crossbow. Saying "they don't hit hard enough" when crossbows can do the job is fundamentally not an issue if you are enabling more people to fight.
The range is a point but not an overwhelming one. You are talking about "have to be within 30ft". Why? Again this is an issue of numbers. They have to be within 120ft, sure. Or take cover. Again, you need more halflings.
But the point of the sling is that every halfling can carry one at all times. It's about 1lb of weight including the stones and you wear it on your belt or in your pockets.
This doesn't mysteriously prevent halflings who think they will need them from wearing shortbows (or, more rarely, light crossbows) on their back. And if they happen to be home when there's a call to deal with invaders then any who have and can use bows will grab them - and possibly those of other people in the house too to bring them.
But the point of the slings is that pretty close to 100% of teenage and adult halflings are ready to defend their community at almost no notice and can and will make a meaningful contribution.
By contrast humans are much more likely to use a formal militia system with designated people on designated days carrying the effective weapons. Wandering round with 6lb of bulky crossbow + bolts on their backs and possibly armour that gets in the way of what they are intending to do that day.
The gnolls are only partially relevant. The big question is which system is better for protecting the village from a range of threats? The one with the designated militia? Or the one by the race noted for its farming where everyone is able to contribute to the defence at a moment's notice even if a slinger only provides about a third of the firepower that a properly equipped militia member does.
If humans can protect a village with a militia then halflings can primarily with slings. And if somewhere would be untenable for halflings then it is for humans.
If, on the other hand the place is so dangerous that all the humans are wearing crossbows or military weapons like polearms at all times then yes, slings aren't enough. But this is a weird village.
Q A Light Crossbow takes them from an average of 4-5 damage (assuming your +2 dex mod, which I'm just giving you at this point) to an average of 6-7 damage. That is doubling their damage.
Check your math.