If guns are applied realistically to the setting, I do not have a big problem with them.
The problem is that medieval-era firearms were very slow to load and inaccurate beyond short range. The main effect was the fear factor from the smoke and the loud noise, which would often scare horses. They were powerful at short-range, but would often not be able to penetrate plate armor at longer ranges.
Firearms were around in the medieval era, but a medieval-era harquebus (or earlier handgun) took a good two minutes to reload, far slower than a crossbow. The effectiveness of medieval-era firearms only came about when they were used in massed groups where rows of harquebusiers would take turns firing while the other rows reloaded.
The revolution of firearms in the early years was that they were far easier to mass produce than bows & arrows and that it was easier to carry around gunpowder and 100 bullets than carrying around a quiver of 20 arrows or crossbow bolts.
Unfortunately, most of the firearms rules for D&D I have seen seemingly make firearms into something that was more like rifles & pistols from the American Civil War era instead of 500 years earlier when guns were something new to Europe and the Middle East. That is not really fair when the rest of the game is based on a fantasy Medieval Europe around 1300AD, give or take 100 years.
Even Civil War era guns were single-shot and took time to reload.
Sure, if you want to use firearms, that is fine, but give them the 20 round reload time that is maybe able to cut down to less time with various feats.