Show The Latest COVID-19 Stats Using JavaScript

Category: Javascript | March 28, 2020
Views Total:701 views
Official Page:Go to website
Last Update:March 28, 2020


Show The Latest COVID-19 Stats Using JavaScript


A pure JavaScript solution to show the live COVID-19 statistics (confirmed cases, recovered patients, and deaths) by country.

Based on

See Also:

How to use it:

1. Create a select element from which the users can select a country to show the live updated stats of the Coronavirus (Covid-19).

<select name="countries" id="countries">
  <option value="all">World</option>

2. Create an empty container to hold the statistics.

<div class="country-stats"></div>

3. Put the main JavaScript index.js at the end of the document. That’s it.

<script src="./index.js" defer></script>

4. By default, the library uses Bootstrap 4 for the styling of the stats.

<link rel="stylesheet" href="/path/to/cdn/bootstrap.min.css" />



  • JS update & bugfixed

You Might Be Interested In:

One thought on “Show The Latest COVID-19 Stats Using JavaScript

  1. Jildine B. Peñas

    Hi sir.. you have an API for Davao city or Davao region?


Leave a Reply