How do I tell if a user is using Brave as their browser?

后端 未结 9 801
旧巷少年郎
旧巷少年郎 2021-02-04 01:29

I have been messing around with the Brave browser (https://www.brave.com/), an I cannot figure out how to determine how if a user is using Brave. I used a simp

9条回答
  •  萌比男神i
    2021-02-04 01:59

    As of April 2020, you can use this detection method to get a boolean answer to whether the user is using Brave or not:

    (navigator.brave && await navigator.brave.isBrave() || false)
    

提交回复
热议问题