1.0.5 • Published 3 years ago

airnow-aqi v1.0.5

Weekly downloads
-
License
ISC
Repository
-
Last release
3 years ago

Airnow AQI

JavaScript utility for converting PPM readings to AQI values (as defined by airnow.gov as of Sept 2018) based on this reference document.

Currently supported pollutant types:

  • PM2.5
  • PM10

Installation

npm install --save airnow-aqi

Usage

import { computeAqi } from "airnow-aqi";
computeAqi([
  // provide an array of type and ppm reading values
  {
    type: "pm2.5", // valid types are "pm2.5" and "pm10"
    ppm: 10,
  }
])

TypeScript typings are provided for this package.