I\'m making a website and I want it to be compatible with the forthcoming Microsoft Edge when it comes out officially. To be more specific, the mobile version of it. Does an
For those looking for a regex to detect IE and Microsoft Edge, I repurposed one from another SO answer and added Edge
/(?:\b(MS)?IE\s+|\bTrident\/7\.0;.*\s+rv:|\bEdge\/)(\d+)/
I made it check for Edge and then a miscellaneous digit in case they decide to iterate the Edge version.
EDIT: To update yes, both Edge and older IE versions are considered very different browsers. My use case required detecting IE branded browsers for marketing purposes (if user is using any Internet Explorer/Edge browser, we wanted to show something for that) but that might not necessarily be the case for you.