Перейти к содержанию

Covid Tracker

This example shows a current statistics about COVID-19 pandemic filtered by countries using XState and React. It contains:

  • covidMachine - handles country selection, including a "sub-state" responsible for fetching the list of all countries across the globe
  • covidDataMachine - handles fetching specific statistics (including confirmed, deaths, recovered cases) based on selected country

The two child components <Indicator /> and <Chart /> that responsibles of rendering data, consumes the service from the MachineProvider context provider