One of the very few things I disagree with Wormerine.
You will have lots of spellslots at higher levels and you also have cantrips that you can always cast. Don't forget that their power increase so they're always usefull.
True, it is not BG1&2 bad nowadays, but I think the problem exists. How big of a problem it is will depend on a player - I am a hoarder type, ending games with hundered of consumables as I would avoid using them, in case I need them later. I can wizard a main, and not use a spell unless I really really have to. Others will use up all their spells and abuse the rest.
Where the problem arises is that devs have no way of encouraging fun playstyle. How do you stop rest-spammers from overpowering encounters by overspending spells? How do you encourage hoarders like myself not to restrict themselves to repetitive, cost efficient playstyles?
That why I usually quote PoE1 as best implimentation of the system - tanks endurance game a pretty clear indication of when we will have to be resting - therefore I could gauge how long I have till rest and use spell appropriatly. Limitation to 2 camping supplies allowed devs to pace dungeons, meaning if you are rest-spammer, doing so will make game too tedious to indulge in that playstyle. Still, it's more of patching dodgy BG1&2 design, then creating a good gameplay loop.
It's odd to have a resource management element, without it actually being a resource management. We can get those resources anywhere at any time. Try to artificially restrict it and we run into another problem - how can we resource manage, if we don't know what ahead us? How can devs design fair encounters if they have no way of knowing how many and what resources we have? The latter leads to either BG1&2/PoE1 were majority of encounters are greatly undertuned, or Kingmaker where metaknowladge is king. Though, techincally, I think BG1&2/PoE1 suffer more from too much optional content (meaning you start overleveling everything if you are thorough). PoE2 moved to per-encounter casting, but it's super felxible open world structre made everything past initial couple hours a cake-walk.