This page was translated from English by the community. Learn more and join the MDN Web Docs community.

View in English Always switch to English

MediaStreamTrack.label

Baseline Widely available

This feature is well established and works across many devices and browser versions. It’s been available across browsers since ⁨2017년 9월⁩.

MediaStreamTrack.label 읽기 전용 속성은 사용자 에이전트가 트랙 소스를 식별하기 위해 지정한 레이블을 담은 DOMString을 반환합니다. 소스가 연결되지 않은 경우 빈 문자열이며, 연결됐던 트랙이 소스에서 분리되더라도 레이블은 바뀌지 않습니다.

구문

js
const label = track.label;

사용자 에이전트가 지정한 식별 레이블. "internal microphone" 등의 형태입니다.

명세

Specification
Media Capture and Streams
# dom-mediastreamtrack-label

브라우저 호환성

같이 보기