Nothing speeds up developement as fast as war does. This was proven during WWI and WWII, As well as with Korean war, and Vietnam war.
How ever this also requires that developement get's far enough before the actual conflict. and at least one of cobatting sides have access to resources that are needed during that conflict.
Also it requires smart, and well educated people. which there were well before our worlds great develpements, Mostly in what's current day China and Japan, and middle east.
It also requiress access to critical resources, with relative ease. Ores, Oils, etc.
Which Europe, and and Asia had in abundance. But also it requires enough fertile land to feed the working class.
It also depends on govening body. Democratic republic, Communist republic, Monarchy, Anarchy, etc. etc. all have benefits, and drawbacks.
Also Religion affects, not to mention that in fantasy setting god and/or gods might have divine intervention. For example I take Lloth "the spider queen" which is a drow/dark elf god, from forgotten realms. If you kill a spider, by accident or not, only suitable punishment is death.
Now think if Plato, Socrates, Aristotele, Einstein, Newton, Darvin, Phytagoras, Galileo, Tesla, or Da Vinci would have faced these punishments at age of 15. Or better yet, what if all of them would have faced this punishment.
Then there is the concept of magic.
Why would you create telephone, or even telegram, if a mage can talk to another mage via chrystal ball, over thuosands of miles of distance.
Why would you invent a lightbulb, if you can buy a fist sized enchanted rock, that illuminates it's surroundings 24/7 for decades.
And even if you would make such inventions, but the region where you make such an invention lacks at least 1 critical resource, that you can import from elsewhere with massive costs, and still risk a ship sinking during delivery, or caravan getting raided on the way.
Inventions might have been done, and where those inventions would lead is a topic on itself. But when there allready is alternative way to do that same thing cheaper with a bit of magic, why would anyone bother.