useAmbientLightSensor
samouss opened this issue · 2 comments
samouss commented
https://developer.mozilla.org/en-US/docs/Web/API/AmbientLightSensor
const App = () => {
const value = useAmbientLightSensor();
if (value > 50) {
return "Light";
}
return "Dark";
};
camflan commented
@samouss I've started this here: https://github.com/camflan/light-sensor
can you give it a shot?
samouss commented
Yep looks good!