/
githubmirror
/
tauri
Обзор
Документация
Войти
/
githubmirror
/
tauri
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
tauri-cli-v2.11.3
examples/streaming/index.html
33 строки
830 B
Lucas Nogueira
fix(examples): streaming file path
27 авг 2024, 03:48
Не верифицирован
27 авг 2024, 03:48
dc0612b
Код
Авторство
О чём код?
<!doctype html> <html lang="en"> <head> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" /> <style> body { margin: unset; overflow: hidden; } video { width: 100vw; height: 100vh; } </style> </head> <body> <video id="video_source" controls="" autoplay="" name="media"> <source type="video/mp4" /> </video> <script> const { invoke, convertFileSrc } = window.__TAURI__.core const video = document.getElementById('video_source') const source = document.createElement('source') source.type = 'video/mp4' source.src = convertFileSrc('streaming_example_test_video.mp4', 'stream') video.appendChild(source) video.load() </script> </body> </html>