# CountryPPPData

This is a script to fetch the the Price Factor data of various countries from the World Bank API. This data is to be interpreted as:

> If a product is sold in the US for X USD, taking the regional economy into consideration, for a fair price, the same product must be sold in another country for (X x Price Factor) USD.

Read more on the Wikipedia [Purchasing Power Parity](https://en.wikipedia.org/wiki/Purchasing_power_parity) page.

This does not have a git repository but the source code can be found on my [GitHub Gist](https://gist.github.com/61c721e41b9a9d81306ad2224dee3c0e). There is a slight chance that this may be out of sync though.

## Support Me

I am an independent developer. Your support can help me work better.

---

> **I am available to be hired full-time, part-time or freelance.**
>
> [![buymeacoffee](<https://img.buymeacoffee.com/button-api/?text=Buy me a book&emoji=📖&slug=quantumcorn&button_colour=bf1d55&font_colour=ffffff&font_family=Comic&outline_colour=ffffff&coffee_colour=FFDD00>)](https://www.buymeacoffee.com/quantumcorn)
>
> [![ko-fi](https://ko-fi.com/img/githubbutton_sm.svg)](https://ko-fi.com/R5R7O37GT)

---

## Documentation

1. **Install**
   `npm install countrypppdata`
2. **Import**
   `const fetchCountryData = require("countrypppdata");`
3. **Use**

   ```js
   const pppDataset = await fetchCountryData();
   pppDataset.map(({ countryCode, countryName, priceFactor }) => {
     //Your logic here
   });
   ```
