Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

covid-charts

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

covid-charts

Interactive charts with the number of Coronavirus confirmed cases, deaths, and recovered cases for your country.

  • 0.1.3
  • latest
  • npm
  • Socket score

Version published
Weekly downloads
1
decreased by-66.67%
Maintainers
1
Weekly downloads
 
Created
Source

covid-charts

Interactive charts with the number of Coronavirus confirmed cases, deaths, and recovered cases for your country.

example

Data from pomber/covid19

install

with npm
npm i covid-charts
import createChart from "covid-charts";

const chart = createChart(document.body, {
  country: "France",
  width: 400,
  height: 300
});
with CDN via unpkg
<script src="https://unpkg.com/covid-charts/index.js"></script>
<script>
  const chart = createChart(document.body, {
    country: "France",
    width: 400,
    height: 300
  });
</script>

api

createChart params:

  • dom element: chart will be added to this place to DOM
  • options:
    • width (default: 400)
    • height (default: 300)
    • country (default: 'China')

createChart return object with next methods:

  • remove: destroy and remove chart from DOM
  • countries: return a promise with available countries
  • changeCountry: change country to the specified

acknowledgements

Thanks @pomber for the data.

Special thanks to tradingview for supa-dupa charts.

FAQs

Package last updated on 10 Dec 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc