I have been playing Icewindale recently, one of the older d&d games. My elf mage at level 1 had 4 hp and the ability to cast 2 spells. After using those spells, all that remained was to throw daggers at foes until I could long rest. By level 4, I still only had maybe 4-6 spells I could use. No unlimited cantrips. Her hp was still only 12.
In BG1 and 2, I played a sorcerer. You know, they really need to get the sorcerer class out for BG3 soon. That might help peoples perceptions of spellcasters. The sorcerer differs from the wizard in that you get more spell slots but the tradeoff is you can't learn as much of a variety of spells.
By level 10, my sorcerer had like 45 HP and could hurl tons of spells each day. I was casting fireball on everything, and I made him more of a summoned, wiping the floor with enemies left and right and summoning wyverns and goblins and ogres and such to fight for me.
But in those games, every long rest in the wild was a chance random encounter. That's how they limited it. The only safe place was an inn at a city.
I don't particularly care how they limit long rests. They just need to. So far the best methods that I've read are either:
1. Story Timed Events, as I detailed in previous posts
2. Prerequisites, as Ive detailed in previous posts
3. Random encounters, as many have also suggested
4. Severely limit fast travel and make only certain areas rest zones
The problem with 1 is people don't want to feel limited or rushed. People are resisting it because they want to be able to spam long rest as much as they can without consequences.
The problem with 2 is if you really need to long rest in order to beat a boss, and you don't meet the requirements, oh well. You're out of luck.
The problem with 3 is that it is pointless unless you severely restrict fast travel. Otherwise, yoy can always annoyingly fast travel to camp and then long rest and then fast travel back. All this does is make you do more work for no reason.
The problem with 4 is that fast travel is nice and really cut down on senseless running through map locations you've already cleared. If you restrict fast travel, it just annoys players rather than prevents long resting. Instead of fast travel to a rest zone, now they have to manually run there. This was an annoying aspect, frankly, of the older games.
My favorite is 1. My second is 2. With 1, you can have more diverse gameplay with different endings and rewards based on how many long rest you use. 2 is more like Solasta, where I got the idea, and it could prove annoying if they do it wrong. I don't really care too much for 3 and 4.