nano includes a fully custom video player built for streaming movies and TV shows. You can choose between a lightweight native HTML5 player and an advanced Vidstack-powered player, both of which support HLS adaptive streaming, automatic subtitle loading, quality selection, and multi-server fallback — all configured through environment variables at deploy time.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/mohameodo/nano/llms.txt
Use this file to discover all available pages before exploring further.
Choosing a player mode
nano exposes theUSE_VIDSTACK environment variable to switch between the two player implementations.
- HTML5 Player (default)
- Vidstack Player
<video> element and hls.js. It includes:- Custom progress bar with seek, buffer indicator, and hover timestamp
- Play/pause, mute, and volume slider controls
- Fullscreen toggle (with landscape lock on mobile)
- Server selector dropdown
- Quality selector (when the source provides multiple levels)
- Download button for direct video links
Server selection
nano routes playback through streaming servers identified by short IDs. The active server is set at startup via theDEFAULT_SERVER environment variable.
rei. In development mode (DEV=true), the default switches to momo and additional servers become available (including xpass, hana, nemu, kisskh, haru, sora, yuki, aoi, ren, nagi, kaede, hina, riku, kaze, noa, akari, and yume).
The server list is defined in config.shiopa.ts as an array of { id, name } objects. Users can switch servers at runtime using the server dropdown in the player header — the currently active server is highlighted with a checkmark.
Autoplay
Control whether playback starts automatically when a video loads:video.play() with a .catch(() => {}) guard to handle browser policy silently.
Subtitles
Subtitles are automatically fetched for the current movie or TV episode and rendered as<track> elements inside the <video> tag (or as Vidstack <track> children). Each subtitle object has the following shape:
sub.vdrk.site using the TMDB ID of the movie or episode. .srt files are converted to WebVTT on-the-fly: the proxy rewrites the timestamp separators (, → .) and prepends the required WEBVTT header before serving the file to the player.
HLS support
For streams delivered as M3U8 playlists, nano useshls.js in the HTML5 player mode. When the source URL contains .m3u8 or /hls/, or when the isM3U8 flag is set, nano initialises an Hls instance with the following configuration:
hls.js and sets the src attribute directly, letting the browser handle playback.
M3U8 playlists served through nano’s /api/proxy endpoint have all segment URLs rewritten to go through the proxy, so every HLS request is proxied rather than hitting the origin server directly from the browser.
In Vidstack mode, the source is passed as:
Quality switching
When the streaming source exposes multiple quality levels (e.g.720p, 1080p, 4K), the HTML5 player renders a quality selector in the control bar. Selecting a quality:
- Saves the current playback position and play/pause state.
- Calls
attachSource()with the new URL. - Seeks back to the saved position once the new source fires
canplay.