Skip to content

navigator.mediaDevices is not available in insecure contexts #1201

@anilanar

Description

@anilanar

lib Update Request

Configuration Check

My compilation target is esnext and my lib is ['esnext', 'dom'].

Missing / Incorrect Definition

navigator.mediaDevices (and potentially everything that doesn't exist in insecure contexts) should be an optional property in the interface.

Documentation Link

Accoding to the spec:

partial interface Navigator {
  [SameObject, SecureContext] readonly attribute MediaDevices mediaDevices;
};

The meaning of SecureContext:

... it indicates that the construct is exposed only within a secure context.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions