@n3p6/use-illuminance
TypeScript icon, indicating that this package has built-in type declarations

0.1.0-beta.2 • Public • Published

@n3p6/use-illuminance

A very small React Hook to help you get illuminance from Ambient Light Sensor API.

Usage

Install

Example

import { useIlluminance } from '@n3p6/use-illuminance'

const App = () => {
  const illuminance = useIlluminance()

  return (
    <div>
      <h1>Illuminance:</h1>
      <span>{illuminance}</span>
    </div>
  )
}

export default App

License

MIT

Readme

Keywords

none

Package Sidebar

Install

npm i @n3p6/use-illuminance

Weekly Downloads

12

Version

0.1.0-beta.2

License

MIT

Unpacked Size

4.84 kB

Total Files

5

Last publish

Collaborators

  • kwaa