html 使用Reactjs在iPhone中无法自动播放视频

6rqinv9w  于 2022-12-02  发布在  React
关注(0)|答案(1)|浏览(195)

我正在Reactjs上工作,我使用nextjs,我有视频(在网站上)这是工作/显示罚款在Android手机,但不工作在iPhone中,我如何解决这个问题?我尝试了以下cdoe

<video   loop autoplay='' muted>
                   <source src= { 'https://xxxxxxxxxxxx.vercel.app/img/video.mp4
' } type="video/mp4" />Your browser does not support the video tag. I suggest you upgrade your browser.
                   <source src={ 'https://xxxxxxxxxxxxxxxxx/img/video.mp4
' } type="video/ogg" />Your browser does not support the video tag. I suggest you upgrade your browser.
               </video>
ux6nzvsh

ux6nzvsh1#

playsinline属性有帮助吗?
这是我的资料

<video autoplay loop muted playsinline class="video-background ">
  <source src="videos/intro-video3.mp4" type="video/mp4">
</video>

相关问题