summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/ambient-light/support-iframe.html
blob: 994642d51372751290a3c4886bff91dc92ecdaf6 (plain)
1
2
3
4
5
6
7
8
9
10
11
<!DOCTYPE HTML>
<meta charset="utf-8">
<input type="text" id="reading" />
<script>

let sensor = new AmbientLightSensor();
sensor.start();
document.getElementById("reading").value = String(sensor.reading);
sensor.stop();

</script>