tgrushka said over 2 years ago on Video Chat with WebRTC :
Wasn't working for me in iOS / mobile Safari -- I was getting a black screen on the videos, I was seeing my mobile video on my desktop, but black videos on mobile -- but audio was working. (I thought: could it be I improperly setup my TURN server or something, or was there some obscure bug/deprecation in the JavaScript?)

Then I found Safari has had a bug (which Apple probably calls a "feature" -- lovely -- https://bugs.webkit.org/show_bug.cgi?id=176843) since iOS 11, which requires playsinline to be true on video elements. Which has nothing to do with user permissions, but rather fullscreen video... weird. The following worked for me:

In video_chat_controller.js, around line 158, after const element = document.createElement("video"), add:
            element.setAttribute('playsinline', '')

Then, in show.html.erb, add playsinline as an attribute on the video tag.

Also, data-video="chat-target.local_video" type of attributes have now been deprecated in Stimulus. The Stimulus error is helpful: just change them to data-video-chat-target="local_video". The full code for that tag would then be:

    <video data-video-chat-target="local_video" playsinline autoplay></video>