g
This commit is contained in:
@@ -26,8 +26,8 @@
|
|||||||
<body>
|
<body>
|
||||||
<video id="remoteVideo" autoplay playsinline controls muted></video>
|
<video id="remoteVideo" autoplay playsinline controls muted></video>
|
||||||
|
|
||||||
<script src="/socket.io/socket.io.js"></script>
|
<script src="./socket.io/socket.io.js"></script>
|
||||||
<script src="mediasoup-client.js"></script>
|
<script src="./mediasoup-client.js"></script>
|
||||||
<script src="viewer.js"></script>
|
<script src="./viewer.js"></script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>Screenshare - Viewer</title>
|
<title>Screenshare - Viewer</title>
|
||||||
<link rel="stylesheet" href="style.css">
|
<link rel="stylesheet" href="./style.css">
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div class="viewer-container">
|
<div class="viewer-container">
|
||||||
@@ -17,8 +17,8 @@
|
|||||||
</div>
|
</div>
|
||||||
<video id="remoteVideo" autoplay playsinline controls muted></video>
|
<video id="remoteVideo" autoplay playsinline controls muted></video>
|
||||||
</div>
|
</div>
|
||||||
<script src="/socket.io/socket.io.js"></script>
|
<script src="./socket.io/socket.io.js"></script>
|
||||||
<script src="mediasoup-client.js"></script>
|
<script src="./mediasoup-client.js"></script>
|
||||||
<script src="viewer.js"></script>
|
<script src="./viewer.js"></script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
const socket = io();
|
const basePath = window.location.pathname.replace(/\/[^\/]+\.[^\/]+$/, '').replace(/\/$/, '');
|
||||||
|
const socket = io({ path: basePath + '/socket.io' });
|
||||||
const remoteVideo = document.getElementById('remoteVideo');
|
const remoteVideo = document.getElementById('remoteVideo');
|
||||||
const overlay = document.getElementById('overlay');
|
const overlay = document.getElementById('overlay');
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user