I highly recommend the Section 8 Tactical ultimate retention device. These work extremely well with 20-25mm flashlights. When I first got a hold of one, it took me a little while to get use to the idea of using them, but after an incident that changed my life, the $16 I spent was worth it. Being able to point a light in a different direction than a gun is extremely important in some situations, especially in your own home. There are are endless scenarios that play out when discussion these topics, but I’ve actually live a few of my own and I am confident that I have the right tools.
Lanyards are in my opinion an old school way of carry a flashlight. If it works for you than good for ya. I put lanyards on some flashlights just so they are harder to loose. Now that so many flashlights have gotten so small, yet powerful, losing that $250, 80 Lumen flashlight has gotten easier and easier. I have some weapon mounted flashlights that are rock soldid and I don’t think I will ever change that, but when it comes to using handguns, I’m not a big fan of putting lights on them. Maybe once Streamlight flashlights technology gets to the point where the flashlight projects from the guide rod and doesn’t inhibit the use of your usual CCW holster or make your gun bulkier, then I’ll change my mind.