3

I get sharing screen by using mediaDevices.getDisplayMedia() and it work well on Chrome and Safari < 15. But when I try it on Safari 15, I hit the bug: invalidAccessError: getdisplaymedia must be called from a user gesture handler

I have viewed the answer: Safari getDisplayMedia must be called from a user gesture handler. They said that the reason is:

This safari error occures due to the event (event that should trigger it) having isTrusted property false. This property is set automatically and is not possible to fake.

When I log event.isTrusted on Safari 15, its value is true. But I still hit the above error. Can you guys help me with this, thanks.

Dat Dang
  • 150
  • 4

1 Answers1

0

You try to enable the experimental feature "Enable MDNS Ice Candidates" in Safari settings, advanced, experimental features

khoi vu
  • 105
  • 1
  • 6