Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

138
Views
how to detect specific versions of browser

I wanted to check if browser is supported or not, I wanted to check the specific browser with browser versions,

How to check if Safari (12.1+) or not ? How to check if Edge (80+) or not ?

I have a function written wanted to modify that to achieve the same..

function isBrowserSupported() {
    let userAgent = navigator.userAgent;
    // let webrtcDetectedBrowser;
    // need to check if should check OS also
    let isBrowserSupported = false;
    if (userAgent.match(/chrome|chromium|crios/i) || (userAgent.match(/firefox|fxios/i)) || (userAgent.match(/safari/i)) || (userAgent.match(/edg/i))) {
        isBrowserSupported = true;
    } 
    return isBrowserSupported;
}

isBrowserSupported() should return true when browser is:

Chrome (MacOS/Windows/Android)
Firefox (MacOS/Windows)
Edge (80+)(Windows)
Safari (12.1+) ((MacOS/iPadOS/iOS)

navigator.userAgent return's this -

> navigator.userAgent
< "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/15.2 Safari/605.1.15"
about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

i hope navigator.userAgentData will solve your problem. you can use navigator.platform for finding platform

console.log(navigator.userAgentData)
console.log(navigator.platform)

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!