blob: 4a07bbf70c1a350e87a8681dcbce5fb51de119c4 [file] [log] [blame]
// Copyright 2017 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// https://wicg.github.io/feature-policy/#the-policy-object
[
Exposed=Window,
RuntimeEnabled=FeaturePolicyJavaScriptInterface,
ImplementedAs=DOMFeaturePolicy
] interface FeaturePolicy {
[MeasureAs=FeaturePolicyJSAPI, CallWith=ScriptState] boolean allowsFeature(DOMString feature, optional DOMString origin);
[MeasureAs=FeaturePolicyJSAPI, CallWith=ScriptState] sequence<DOMString> features();
[MeasureAs=FeaturePolicyJSAPI, CallWith=ScriptState] sequence<DOMString> allowedFeatures();
[MeasureAs=FeaturePolicyJSAPI, CallWith=ScriptState] sequence<DOMString> getAllowlistForFeature(DOMString feature);
};