From 92b5fffd8f94f165f5566b9a49790eedcadd0693 Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Mon, 14 Mar 2022 01:49:41 +0530 Subject: [PATCH 01/18] Create index.js --- JavaScript/GetCovid19Statistics/index.js | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 JavaScript/GetCovid19Statistics/index.js diff --git a/JavaScript/GetCovid19Statistics/index.js b/JavaScript/GetCovid19Statistics/index.js new file mode 100644 index 000000000..30fdf6cc4 --- /dev/null +++ b/JavaScript/GetCovid19Statistics/index.js @@ -0,0 +1,7 @@ +const covid19 = require('covid19-stats') +const main = async (inputs, auths, context) => { + const country = inputs.country + var stats = await covid19.getCountry(country) + return stats +} +module.exports.main = main From 21a91617f37885275d2bb9301e672ba227a92d35 Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Mon, 14 Mar 2022 01:50:54 +0530 Subject: [PATCH 02/18] Create package.json --- JavaScript/GetCovid19Statistics/package.json | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 JavaScript/GetCovid19Statistics/package.json diff --git a/JavaScript/GetCovid19Statistics/package.json b/JavaScript/GetCovid19Statistics/package.json new file mode 100644 index 000000000..c48d662c8 --- /dev/null +++ b/JavaScript/GetCovid19Statistics/package.json @@ -0,0 +1,15 @@ +{ + "name": "GetCovid19Statistics", + "version": "1.0.0", + "description": "", + "main": "index.js", + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1" + }, + "keywords": [], + "author": "", + "license": "ISC", + "dependencies": { + "covid19-stats": "^1.1.3" + } +} From 1c67f7af948fba551fd2dbe729b2821abe2b5127 Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Mon, 14 Mar 2022 01:52:03 +0530 Subject: [PATCH 03/18] Create package_lock.json --- .../GetCovid19Statistics/package_lock.json | 153 ++++++++++++++++++ 1 file changed, 153 insertions(+) create mode 100644 JavaScript/GetCovid19Statistics/package_lock.json diff --git a/JavaScript/GetCovid19Statistics/package_lock.json b/JavaScript/GetCovid19Statistics/package_lock.json new file mode 100644 index 000000000..677d74e25 --- /dev/null +++ b/JavaScript/GetCovid19Statistics/package_lock.json @@ -0,0 +1,153 @@ +{ + "name": "GetCovid19Statistics", + "version": "1.0.0", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "axios": { + "version": "0.21.4", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.21.4.tgz", + "integrity": "sha512-ut5vewkiu8jjGBdqpM44XxjuCjq9LAKeHVmoVfHVzy8eHgxxq8SbAVQNovDA8mVi05kP0Ea/n/UzcSHcTJQfNg==", + "requires": { + "follow-redirects": "^1.14.0" + } + }, + "boolbase": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz", + "integrity": "sha1-aN/1++YMUes3cl6p4+0xDcwed24=" + }, + "cheerio": { + "version": "1.0.0-rc.10", + "resolved": "https://registry.npmjs.org/cheerio/-/cheerio-1.0.0-rc.10.tgz", + "integrity": "sha512-g0J0q/O6mW8z5zxQ3A8E8J1hUgp4SMOvEoW/x84OwyHKe/Zccz83PVT4y5Crcr530FV6NgmKI1qvGTKVl9XXVw==", + "requires": { + "cheerio-select": "^1.5.0", + "dom-serializer": "^1.3.2", + "domhandler": "^4.2.0", + "htmlparser2": "^6.1.0", + "parse5": "^6.0.1", + "parse5-htmlparser2-tree-adapter": "^6.0.1", + "tslib": "^2.2.0" + } + }, + "cheerio-select": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/cheerio-select/-/cheerio-select-1.5.0.tgz", + "integrity": "sha512-qocaHPv5ypefh6YNxvnbABM07KMxExbtbfuJoIie3iZXX1ERwYmJcIiRrr9H05ucQP1k28dav8rpdDgjQd8drg==", + "requires": { + "css-select": "^4.1.3", + "css-what": "^5.0.1", + "domelementtype": "^2.2.0", + "domhandler": "^4.2.0", + "domutils": "^2.7.0" + } + }, + "covid19-stats": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/covid19-stats/-/covid19-stats-1.1.3.tgz", + "integrity": "sha512-HKRGs8DghApQAiu7XJ1THhlJ8gwm6TAHsA1L1kbZDMukUOsVrWuYPDnx0qylvMBd6gw9burNIl/kAowyn//JfQ==", + "requires": { + "axios": "^0.21.1", + "cheerio": "^1.0.0-rc.10" + } + }, + "css-select": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/css-select/-/css-select-4.2.1.tgz", + "integrity": "sha512-/aUslKhzkTNCQUB2qTX84lVmfia9NyjP3WpDGtj/WxhwBzWBYUV3DgUpurHTme8UTPcPlAD1DJ+b0nN/t50zDQ==", + "requires": { + "boolbase": "^1.0.0", + "css-what": "^5.1.0", + "domhandler": "^4.3.0", + "domutils": "^2.8.0", + "nth-check": "^2.0.1" + } + }, + "css-what": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/css-what/-/css-what-5.1.0.tgz", + "integrity": "sha512-arSMRWIIFY0hV8pIxZMEfmMI47Wj3R/aWpZDDxWYCPEiOMv6tfOrnpDtgxBYPEQD4V0Y/958+1TdC3iWTFcUPw==" + }, + "dom-serializer": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.3.2.tgz", + "integrity": "sha512-5c54Bk5Dw4qAxNOI1pFEizPSjVsx5+bpJKmL2kPn8JhBUq2q09tTCa3mjijun2NfK78NMouDYNMBkOrPZiS+ig==", + "requires": { + "domelementtype": "^2.0.1", + "domhandler": "^4.2.0", + "entities": "^2.0.0" + } + }, + "domelementtype": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.2.0.tgz", + "integrity": "sha512-DtBMo82pv1dFtUmHyr48beiuq792Sxohr+8Hm9zoxklYPfa6n0Z3Byjj2IV7bmr2IyqClnqEQhfgHJJ5QF0R5A==" + }, + "domhandler": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.0.tgz", + "integrity": "sha512-fC0aXNQXqKSFTr2wDNZDhsEYjCiYsDWl3D01kwt25hm1YIPyDGHvvi3rw+PLqHAl/m71MaiF7d5zvBr0p5UB2g==", + "requires": { + "domelementtype": "^2.2.0" + } + }, + "domutils": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", + "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", + "requires": { + "dom-serializer": "^1.0.1", + "domelementtype": "^2.2.0", + "domhandler": "^4.2.0" + } + }, + "entities": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", + "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==" + }, + "follow-redirects": { + "version": "1.14.7", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.14.7.tgz", + "integrity": "sha512-+hbxoLbFMbRKDwohX8GkTataGqO6Jb7jGwpAlwgy2bIz25XtRm7KEzJM76R1WiNT5SwZkX4Y75SwBolkpmE7iQ==" + }, + "htmlparser2": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-6.1.0.tgz", + "integrity": "sha512-gyyPk6rgonLFEDGoeRgQNaEUvdJ4ktTmmUh/h2t7s+M8oPpIPxgNACWa+6ESR57kXstwqPiCut0V8NRpcwgU7A==", + "requires": { + "domelementtype": "^2.0.1", + "domhandler": "^4.0.0", + "domutils": "^2.5.2", + "entities": "^2.0.0" + } + }, + "nth-check": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-2.0.1.tgz", + "integrity": "sha512-it1vE95zF6dTT9lBsYbxvqh0Soy4SPowchj0UBGj/V6cTPnXXtQOPUbhZ6CmGzAD/rW22LQK6E96pcdJXk4A4w==", + "requires": { + "boolbase": "^1.0.0" + } + }, + "parse5": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-6.0.1.tgz", + "integrity": "sha512-Ofn/CTFzRGTTxwpNEs9PP93gXShHcTq255nzRYSKe8AkVpZY7e1fpmTfOyoIvjP5HG7Z2ZM7VS9PPhQGW2pOpw==" + }, + "parse5-htmlparser2-tree-adapter": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/parse5-htmlparser2-tree-adapter/-/parse5-htmlparser2-tree-adapter-6.0.1.tgz", + "integrity": "sha512-qPuWvbLgvDGilKc5BoicRovlT4MtYT6JfJyBOMDsKoiT+GiuP5qyrPCnR9HcPECIJJmZh5jRndyNThnhhb/vlA==", + "requires": { + "parse5": "^6.0.1" + } + }, + "tslib": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.3.1.tgz", + "integrity": "sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw==" + } + } +} From d5d6eebe515600d9f104786fd643c826f243a9bb Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Mon, 14 Mar 2022 01:53:19 +0530 Subject: [PATCH 04/18] Create dcoder_run.yml --- JavaScript/GetCovid19Statistics/dcoder_run.yml | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 JavaScript/GetCovid19Statistics/dcoder_run.yml diff --git a/JavaScript/GetCovid19Statistics/dcoder_run.yml b/JavaScript/GetCovid19Statistics/dcoder_run.yml new file mode 100644 index 000000000..e901e4b8a --- /dev/null +++ b/JavaScript/GetCovid19Statistics/dcoder_run.yml @@ -0,0 +1,6 @@ +commands: + - run: | + npm i + npm i -g @vercel/ncc + ncc build + default: true From c6ad5846745ba7e74dad6629a44b5511c6360aa7 Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Mon, 14 Mar 2022 01:54:57 +0530 Subject: [PATCH 05/18] Create dcoder_block.yml --- JavaScript/GetCovid19Statistics/dcoder_block.yml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 JavaScript/GetCovid19Statistics/dcoder_block.yml diff --git a/JavaScript/GetCovid19Statistics/dcoder_block.yml b/JavaScript/GetCovid19Statistics/dcoder_block.yml new file mode 100644 index 000000000..5d1003fd9 --- /dev/null +++ b/JavaScript/GetCovid19Statistics/dcoder_block.yml @@ -0,0 +1,14 @@ +id: COVID19_STATS +fileName: dist/index.js +runFunction: main +auths: [] +env: null +inputs: + - name: country + type: Text + description: Input the country you want to see the stats of + required: true +output: + name: covid19StatsReport + description: Covid-19 statistics report + type: JsonArray From 11150087b7ba36ea40189c0bd5b2e5cafd1139fa Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Sun, 27 Mar 2022 02:34:19 +0530 Subject: [PATCH 06/18] Delete dcoder_block.yml --- JavaScript/GetCovid19Statistics/dcoder_block.yml | 14 -------------- 1 file changed, 14 deletions(-) delete mode 100644 JavaScript/GetCovid19Statistics/dcoder_block.yml diff --git a/JavaScript/GetCovid19Statistics/dcoder_block.yml b/JavaScript/GetCovid19Statistics/dcoder_block.yml deleted file mode 100644 index 5d1003fd9..000000000 --- a/JavaScript/GetCovid19Statistics/dcoder_block.yml +++ /dev/null @@ -1,14 +0,0 @@ -id: COVID19_STATS -fileName: dist/index.js -runFunction: main -auths: [] -env: null -inputs: - - name: country - type: Text - description: Input the country you want to see the stats of - required: true -output: - name: covid19StatsReport - description: Covid-19 statistics report - type: JsonArray From e669f7f60bd679e774ec58a80c37cf85c742d0fa Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Sun, 27 Mar 2022 02:34:34 +0530 Subject: [PATCH 07/18] Delete dcoder_run.yml --- JavaScript/GetCovid19Statistics/dcoder_run.yml | 6 ------ 1 file changed, 6 deletions(-) delete mode 100644 JavaScript/GetCovid19Statistics/dcoder_run.yml diff --git a/JavaScript/GetCovid19Statistics/dcoder_run.yml b/JavaScript/GetCovid19Statistics/dcoder_run.yml deleted file mode 100644 index e901e4b8a..000000000 --- a/JavaScript/GetCovid19Statistics/dcoder_run.yml +++ /dev/null @@ -1,6 +0,0 @@ -commands: - - run: | - npm i - npm i -g @vercel/ncc - ncc build - default: true From 7bd5c0cbc9eb31a2ded93c4663ebd826bb754c77 Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Sun, 27 Mar 2022 02:34:51 +0530 Subject: [PATCH 08/18] Delete index.js --- JavaScript/GetCovid19Statistics/index.js | 7 ------- 1 file changed, 7 deletions(-) delete mode 100644 JavaScript/GetCovid19Statistics/index.js diff --git a/JavaScript/GetCovid19Statistics/index.js b/JavaScript/GetCovid19Statistics/index.js deleted file mode 100644 index 30fdf6cc4..000000000 --- a/JavaScript/GetCovid19Statistics/index.js +++ /dev/null @@ -1,7 +0,0 @@ -const covid19 = require('covid19-stats') -const main = async (inputs, auths, context) => { - const country = inputs.country - var stats = await covid19.getCountry(country) - return stats -} -module.exports.main = main From 1b4d1caff4ae7c661b3c3e4a16fb8bb296818870 Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Sun, 27 Mar 2022 02:35:48 +0530 Subject: [PATCH 09/18] Delete package.json --- JavaScript/GetCovid19Statistics/package.json | 15 --------------- 1 file changed, 15 deletions(-) delete mode 100644 JavaScript/GetCovid19Statistics/package.json diff --git a/JavaScript/GetCovid19Statistics/package.json b/JavaScript/GetCovid19Statistics/package.json deleted file mode 100644 index c48d662c8..000000000 --- a/JavaScript/GetCovid19Statistics/package.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "name": "GetCovid19Statistics", - "version": "1.0.0", - "description": "", - "main": "index.js", - "scripts": { - "test": "echo \"Error: no test specified\" && exit 1" - }, - "keywords": [], - "author": "", - "license": "ISC", - "dependencies": { - "covid19-stats": "^1.1.3" - } -} From 055911e5c57f2634a6ddcd8d215ea9d84cc4540d Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Sun, 27 Mar 2022 02:36:12 +0530 Subject: [PATCH 10/18] Delete package_lock.json --- .../GetCovid19Statistics/package_lock.json | 153 ------------------ 1 file changed, 153 deletions(-) delete mode 100644 JavaScript/GetCovid19Statistics/package_lock.json diff --git a/JavaScript/GetCovid19Statistics/package_lock.json b/JavaScript/GetCovid19Statistics/package_lock.json deleted file mode 100644 index 677d74e25..000000000 --- a/JavaScript/GetCovid19Statistics/package_lock.json +++ /dev/null @@ -1,153 +0,0 @@ -{ - "name": "GetCovid19Statistics", - "version": "1.0.0", - "lockfileVersion": 1, - "requires": true, - "dependencies": { - "axios": { - "version": "0.21.4", - "resolved": "https://registry.npmjs.org/axios/-/axios-0.21.4.tgz", - "integrity": "sha512-ut5vewkiu8jjGBdqpM44XxjuCjq9LAKeHVmoVfHVzy8eHgxxq8SbAVQNovDA8mVi05kP0Ea/n/UzcSHcTJQfNg==", - "requires": { - "follow-redirects": "^1.14.0" - } - }, - "boolbase": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz", - "integrity": "sha1-aN/1++YMUes3cl6p4+0xDcwed24=" - }, - "cheerio": { - "version": "1.0.0-rc.10", - "resolved": "https://registry.npmjs.org/cheerio/-/cheerio-1.0.0-rc.10.tgz", - "integrity": "sha512-g0J0q/O6mW8z5zxQ3A8E8J1hUgp4SMOvEoW/x84OwyHKe/Zccz83PVT4y5Crcr530FV6NgmKI1qvGTKVl9XXVw==", - "requires": { - "cheerio-select": "^1.5.0", - "dom-serializer": "^1.3.2", - "domhandler": "^4.2.0", - "htmlparser2": "^6.1.0", - "parse5": "^6.0.1", - "parse5-htmlparser2-tree-adapter": "^6.0.1", - "tslib": "^2.2.0" - } - }, - "cheerio-select": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/cheerio-select/-/cheerio-select-1.5.0.tgz", - "integrity": "sha512-qocaHPv5ypefh6YNxvnbABM07KMxExbtbfuJoIie3iZXX1ERwYmJcIiRrr9H05ucQP1k28dav8rpdDgjQd8drg==", - "requires": { - "css-select": "^4.1.3", - "css-what": "^5.0.1", - "domelementtype": "^2.2.0", - "domhandler": "^4.2.0", - "domutils": "^2.7.0" - } - }, - "covid19-stats": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/covid19-stats/-/covid19-stats-1.1.3.tgz", - "integrity": "sha512-HKRGs8DghApQAiu7XJ1THhlJ8gwm6TAHsA1L1kbZDMukUOsVrWuYPDnx0qylvMBd6gw9burNIl/kAowyn//JfQ==", - "requires": { - "axios": "^0.21.1", - "cheerio": "^1.0.0-rc.10" - } - }, - "css-select": { - "version": "4.2.1", - "resolved": "https://registry.npmjs.org/css-select/-/css-select-4.2.1.tgz", - "integrity": "sha512-/aUslKhzkTNCQUB2qTX84lVmfia9NyjP3WpDGtj/WxhwBzWBYUV3DgUpurHTme8UTPcPlAD1DJ+b0nN/t50zDQ==", - "requires": { - "boolbase": "^1.0.0", - "css-what": "^5.1.0", - "domhandler": "^4.3.0", - "domutils": "^2.8.0", - "nth-check": "^2.0.1" - } - }, - "css-what": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/css-what/-/css-what-5.1.0.tgz", - "integrity": "sha512-arSMRWIIFY0hV8pIxZMEfmMI47Wj3R/aWpZDDxWYCPEiOMv6tfOrnpDtgxBYPEQD4V0Y/958+1TdC3iWTFcUPw==" - }, - "dom-serializer": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.3.2.tgz", - "integrity": "sha512-5c54Bk5Dw4qAxNOI1pFEizPSjVsx5+bpJKmL2kPn8JhBUq2q09tTCa3mjijun2NfK78NMouDYNMBkOrPZiS+ig==", - "requires": { - "domelementtype": "^2.0.1", - "domhandler": "^4.2.0", - "entities": "^2.0.0" - } - }, - "domelementtype": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.2.0.tgz", - "integrity": "sha512-DtBMo82pv1dFtUmHyr48beiuq792Sxohr+8Hm9zoxklYPfa6n0Z3Byjj2IV7bmr2IyqClnqEQhfgHJJ5QF0R5A==" - }, - "domhandler": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.0.tgz", - "integrity": "sha512-fC0aXNQXqKSFTr2wDNZDhsEYjCiYsDWl3D01kwt25hm1YIPyDGHvvi3rw+PLqHAl/m71MaiF7d5zvBr0p5UB2g==", - "requires": { - "domelementtype": "^2.2.0" - } - }, - "domutils": { - "version": "2.8.0", - "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", - "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", - "requires": { - "dom-serializer": "^1.0.1", - "domelementtype": "^2.2.0", - "domhandler": "^4.2.0" - } - }, - "entities": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", - "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==" - }, - "follow-redirects": { - "version": "1.14.7", - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.14.7.tgz", - "integrity": "sha512-+hbxoLbFMbRKDwohX8GkTataGqO6Jb7jGwpAlwgy2bIz25XtRm7KEzJM76R1WiNT5SwZkX4Y75SwBolkpmE7iQ==" - }, - "htmlparser2": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-6.1.0.tgz", - "integrity": "sha512-gyyPk6rgonLFEDGoeRgQNaEUvdJ4ktTmmUh/h2t7s+M8oPpIPxgNACWa+6ESR57kXstwqPiCut0V8NRpcwgU7A==", - "requires": { - "domelementtype": "^2.0.1", - "domhandler": "^4.0.0", - "domutils": "^2.5.2", - "entities": "^2.0.0" - } - }, - "nth-check": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-2.0.1.tgz", - "integrity": "sha512-it1vE95zF6dTT9lBsYbxvqh0Soy4SPowchj0UBGj/V6cTPnXXtQOPUbhZ6CmGzAD/rW22LQK6E96pcdJXk4A4w==", - "requires": { - "boolbase": "^1.0.0" - } - }, - "parse5": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/parse5/-/parse5-6.0.1.tgz", - "integrity": "sha512-Ofn/CTFzRGTTxwpNEs9PP93gXShHcTq255nzRYSKe8AkVpZY7e1fpmTfOyoIvjP5HG7Z2ZM7VS9PPhQGW2pOpw==" - }, - "parse5-htmlparser2-tree-adapter": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/parse5-htmlparser2-tree-adapter/-/parse5-htmlparser2-tree-adapter-6.0.1.tgz", - "integrity": "sha512-qPuWvbLgvDGilKc5BoicRovlT4MtYT6JfJyBOMDsKoiT+GiuP5qyrPCnR9HcPECIJJmZh5jRndyNThnhhb/vlA==", - "requires": { - "parse5": "^6.0.1" - } - }, - "tslib": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.3.1.tgz", - "integrity": "sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw==" - } - } -} From 931a6ed7153bb64355be53d8872774d271f035b5 Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Sun, 27 Mar 2022 02:40:58 +0530 Subject: [PATCH 11/18] Create README.md --- JavaScript/GetCovid19Statistics/README.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 JavaScript/GetCovid19Statistics/README.md diff --git a/JavaScript/GetCovid19Statistics/README.md b/JavaScript/GetCovid19Statistics/README.md new file mode 100644 index 000000000..22f4410c4 --- /dev/null +++ b/JavaScript/GetCovid19Statistics/README.md @@ -0,0 +1 @@ +## Script to retrieve COVID-19 stats using country name From 2ee5405d1fb8a9d48123efdf89f9eabdeae5667b Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Sun, 27 Mar 2022 03:13:37 +0530 Subject: [PATCH 12/18] Add files via upload --- JavaScript/GetCovid19Statistics/index.js | 11 + .../GetCovid19Statistics/package-lock.json | 420 ++++++++++++++++++ JavaScript/GetCovid19Statistics/package.json | 16 + 3 files changed, 447 insertions(+) create mode 100644 JavaScript/GetCovid19Statistics/index.js create mode 100644 JavaScript/GetCovid19Statistics/package-lock.json create mode 100644 JavaScript/GetCovid19Statistics/package.json diff --git a/JavaScript/GetCovid19Statistics/index.js b/JavaScript/GetCovid19Statistics/index.js new file mode 100644 index 000000000..b8fc61fb6 --- /dev/null +++ b/JavaScript/GetCovid19Statistics/index.js @@ -0,0 +1,11 @@ +const covid19 = require('covid19-stats'); +const prompt = require('prompt-sync')(); +async function main() { + const country = prompt('Enter the name of the country you need Covid statistics of: '); + console.log("Details: "); + let stats = await covid19.getCountry(country); + console.log(stats); +} +module.exports.main = main +main(); + diff --git a/JavaScript/GetCovid19Statistics/package-lock.json b/JavaScript/GetCovid19Statistics/package-lock.json new file mode 100644 index 000000000..c29ad3869 --- /dev/null +++ b/JavaScript/GetCovid19Statistics/package-lock.json @@ -0,0 +1,420 @@ +{ + "name": "getcovid19stats", + "version": "1.0.0", + "lockfileVersion": 2, + "requires": true, + "packages": { + "": { + "name": "getcovid19stats", + "version": "1.0.0", + "license": "ISC", + "dependencies": { + "covid19-stats": "^1.1.3", + "prompt-sync": "4.2.0" + } + }, + "node_modules/ansi-regex": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.1.tgz", + "integrity": "sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g==", + "engines": { + "node": ">=6" + } + }, + "node_modules/axios": { + "version": "0.21.4", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.21.4.tgz", + "integrity": "sha512-ut5vewkiu8jjGBdqpM44XxjuCjq9LAKeHVmoVfHVzy8eHgxxq8SbAVQNovDA8mVi05kP0Ea/n/UzcSHcTJQfNg==", + "dependencies": { + "follow-redirects": "^1.14.0" + } + }, + "node_modules/boolbase": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz", + "integrity": "sha1-aN/1++YMUes3cl6p4+0xDcwed24=" + }, + "node_modules/cheerio": { + "version": "1.0.0-rc.10", + "resolved": "https://registry.npmjs.org/cheerio/-/cheerio-1.0.0-rc.10.tgz", + "integrity": "sha512-g0J0q/O6mW8z5zxQ3A8E8J1hUgp4SMOvEoW/x84OwyHKe/Zccz83PVT4y5Crcr530FV6NgmKI1qvGTKVl9XXVw==", + "dependencies": { + "cheerio-select": "^1.5.0", + "dom-serializer": "^1.3.2", + "domhandler": "^4.2.0", + "htmlparser2": "^6.1.0", + "parse5": "^6.0.1", + "parse5-htmlparser2-tree-adapter": "^6.0.1", + "tslib": "^2.2.0" + }, + "engines": { + "node": ">= 6" + }, + "funding": { + "url": "https://github.com/cheeriojs/cheerio?sponsor=1" + } + }, + "node_modules/cheerio-select": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/cheerio-select/-/cheerio-select-1.5.0.tgz", + "integrity": "sha512-qocaHPv5ypefh6YNxvnbABM07KMxExbtbfuJoIie3iZXX1ERwYmJcIiRrr9H05ucQP1k28dav8rpdDgjQd8drg==", + "dependencies": { + "css-select": "^4.1.3", + "css-what": "^5.0.1", + "domelementtype": "^2.2.0", + "domhandler": "^4.2.0", + "domutils": "^2.7.0" + }, + "funding": { + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/covid19-stats": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/covid19-stats/-/covid19-stats-1.1.3.tgz", + "integrity": "sha512-HKRGs8DghApQAiu7XJ1THhlJ8gwm6TAHsA1L1kbZDMukUOsVrWuYPDnx0qylvMBd6gw9burNIl/kAowyn//JfQ==", + "dependencies": { + "axios": "^0.21.1", + "cheerio": "^1.0.0-rc.10" + } + }, + "node_modules/css-select": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/css-select/-/css-select-4.2.1.tgz", + "integrity": "sha512-/aUslKhzkTNCQUB2qTX84lVmfia9NyjP3WpDGtj/WxhwBzWBYUV3DgUpurHTme8UTPcPlAD1DJ+b0nN/t50zDQ==", + "dependencies": { + "boolbase": "^1.0.0", + "css-what": "^5.1.0", + "domhandler": "^4.3.0", + "domutils": "^2.8.0", + "nth-check": "^2.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/css-what": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/css-what/-/css-what-5.1.0.tgz", + "integrity": "sha512-arSMRWIIFY0hV8pIxZMEfmMI47Wj3R/aWpZDDxWYCPEiOMv6tfOrnpDtgxBYPEQD4V0Y/958+1TdC3iWTFcUPw==", + "engines": { + "node": ">= 6" + }, + "funding": { + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/dom-serializer": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.3.2.tgz", + "integrity": "sha512-5c54Bk5Dw4qAxNOI1pFEizPSjVsx5+bpJKmL2kPn8JhBUq2q09tTCa3mjijun2NfK78NMouDYNMBkOrPZiS+ig==", + "dependencies": { + "domelementtype": "^2.0.1", + "domhandler": "^4.2.0", + "entities": "^2.0.0" + }, + "funding": { + "url": "https://github.com/cheeriojs/dom-serializer?sponsor=1" + } + }, + "node_modules/domelementtype": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.2.0.tgz", + "integrity": "sha512-DtBMo82pv1dFtUmHyr48beiuq792Sxohr+8Hm9zoxklYPfa6n0Z3Byjj2IV7bmr2IyqClnqEQhfgHJJ5QF0R5A==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + ] + }, + "node_modules/domhandler": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.0.tgz", + "integrity": "sha512-fC0aXNQXqKSFTr2wDNZDhsEYjCiYsDWl3D01kwt25hm1YIPyDGHvvi3rw+PLqHAl/m71MaiF7d5zvBr0p5UB2g==", + "dependencies": { + "domelementtype": "^2.2.0" + }, + "engines": { + "node": ">= 4" + }, + "funding": { + "url": "https://github.com/fb55/domhandler?sponsor=1" + } + }, + "node_modules/domutils": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", + "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", + "dependencies": { + "dom-serializer": "^1.0.1", + "domelementtype": "^2.2.0", + "domhandler": "^4.2.0" + }, + "funding": { + "url": "https://github.com/fb55/domutils?sponsor=1" + } + }, + "node_modules/entities": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", + "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==", + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/follow-redirects": { + "version": "1.14.7", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.14.7.tgz", + "integrity": "sha512-+hbxoLbFMbRKDwohX8GkTataGqO6Jb7jGwpAlwgy2bIz25XtRm7KEzJM76R1WiNT5SwZkX4Y75SwBolkpmE7iQ==", + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/RubenVerborgh" + } + ], + "engines": { + "node": ">=4.0" + }, + "peerDependenciesMeta": { + "debug": { + "optional": true + } + } + }, + "node_modules/htmlparser2": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-6.1.0.tgz", + "integrity": "sha512-gyyPk6rgonLFEDGoeRgQNaEUvdJ4ktTmmUh/h2t7s+M8oPpIPxgNACWa+6ESR57kXstwqPiCut0V8NRpcwgU7A==", + "funding": [ + "https://github.com/fb55/htmlparser2?sponsor=1", + { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + ], + "dependencies": { + "domelementtype": "^2.0.1", + "domhandler": "^4.0.0", + "domutils": "^2.5.2", + "entities": "^2.0.0" + } + }, + "node_modules/nth-check": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-2.0.1.tgz", + "integrity": "sha512-it1vE95zF6dTT9lBsYbxvqh0Soy4SPowchj0UBGj/V6cTPnXXtQOPUbhZ6CmGzAD/rW22LQK6E96pcdJXk4A4w==", + "dependencies": { + "boolbase": "^1.0.0" + }, + "funding": { + "url": "https://github.com/fb55/nth-check?sponsor=1" + } + }, + "node_modules/parse5": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-6.0.1.tgz", + "integrity": "sha512-Ofn/CTFzRGTTxwpNEs9PP93gXShHcTq255nzRYSKe8AkVpZY7e1fpmTfOyoIvjP5HG7Z2ZM7VS9PPhQGW2pOpw==" + }, + "node_modules/parse5-htmlparser2-tree-adapter": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/parse5-htmlparser2-tree-adapter/-/parse5-htmlparser2-tree-adapter-6.0.1.tgz", + "integrity": "sha512-qPuWvbLgvDGilKc5BoicRovlT4MtYT6JfJyBOMDsKoiT+GiuP5qyrPCnR9HcPECIJJmZh5jRndyNThnhhb/vlA==", + "dependencies": { + "parse5": "^6.0.1" + } + }, + "node_modules/prompt-sync": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/prompt-sync/-/prompt-sync-4.2.0.tgz", + "integrity": "sha512-BuEzzc5zptP5LsgV5MZETjDaKSWfchl5U9Luiu8SKp7iZWD5tZalOxvNcZRwv+d2phNFr8xlbxmFNcRKfJOzJw==", + "dependencies": { + "strip-ansi": "^5.0.0" + } + }, + "node_modules/strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dependencies": { + "ansi-regex": "^4.1.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/tslib": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.3.1.tgz", + "integrity": "sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw==" + } + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.1.tgz", + "integrity": "sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g==" + }, + "axios": { + "version": "0.21.4", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.21.4.tgz", + "integrity": "sha512-ut5vewkiu8jjGBdqpM44XxjuCjq9LAKeHVmoVfHVzy8eHgxxq8SbAVQNovDA8mVi05kP0Ea/n/UzcSHcTJQfNg==", + "requires": { + "follow-redirects": "^1.14.0" + } + }, + "boolbase": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz", + "integrity": "sha1-aN/1++YMUes3cl6p4+0xDcwed24=" + }, + "cheerio": { + "version": "1.0.0-rc.10", + "resolved": "https://registry.npmjs.org/cheerio/-/cheerio-1.0.0-rc.10.tgz", + "integrity": "sha512-g0J0q/O6mW8z5zxQ3A8E8J1hUgp4SMOvEoW/x84OwyHKe/Zccz83PVT4y5Crcr530FV6NgmKI1qvGTKVl9XXVw==", + "requires": { + "cheerio-select": "^1.5.0", + "dom-serializer": "^1.3.2", + "domhandler": "^4.2.0", + "htmlparser2": "^6.1.0", + "parse5": "^6.0.1", + "parse5-htmlparser2-tree-adapter": "^6.0.1", + "tslib": "^2.2.0" + } + }, + "cheerio-select": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/cheerio-select/-/cheerio-select-1.5.0.tgz", + "integrity": "sha512-qocaHPv5ypefh6YNxvnbABM07KMxExbtbfuJoIie3iZXX1ERwYmJcIiRrr9H05ucQP1k28dav8rpdDgjQd8drg==", + "requires": { + "css-select": "^4.1.3", + "css-what": "^5.0.1", + "domelementtype": "^2.2.0", + "domhandler": "^4.2.0", + "domutils": "^2.7.0" + } + }, + "covid19-stats": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/covid19-stats/-/covid19-stats-1.1.3.tgz", + "integrity": "sha512-HKRGs8DghApQAiu7XJ1THhlJ8gwm6TAHsA1L1kbZDMukUOsVrWuYPDnx0qylvMBd6gw9burNIl/kAowyn//JfQ==", + "requires": { + "axios": "^0.21.1", + "cheerio": "^1.0.0-rc.10" + } + }, + "css-select": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/css-select/-/css-select-4.2.1.tgz", + "integrity": "sha512-/aUslKhzkTNCQUB2qTX84lVmfia9NyjP3WpDGtj/WxhwBzWBYUV3DgUpurHTme8UTPcPlAD1DJ+b0nN/t50zDQ==", + "requires": { + "boolbase": "^1.0.0", + "css-what": "^5.1.0", + "domhandler": "^4.3.0", + "domutils": "^2.8.0", + "nth-check": "^2.0.1" + } + }, + "css-what": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/css-what/-/css-what-5.1.0.tgz", + "integrity": "sha512-arSMRWIIFY0hV8pIxZMEfmMI47Wj3R/aWpZDDxWYCPEiOMv6tfOrnpDtgxBYPEQD4V0Y/958+1TdC3iWTFcUPw==" + }, + "dom-serializer": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.3.2.tgz", + "integrity": "sha512-5c54Bk5Dw4qAxNOI1pFEizPSjVsx5+bpJKmL2kPn8JhBUq2q09tTCa3mjijun2NfK78NMouDYNMBkOrPZiS+ig==", + "requires": { + "domelementtype": "^2.0.1", + "domhandler": "^4.2.0", + "entities": "^2.0.0" + } + }, + "domelementtype": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.2.0.tgz", + "integrity": "sha512-DtBMo82pv1dFtUmHyr48beiuq792Sxohr+8Hm9zoxklYPfa6n0Z3Byjj2IV7bmr2IyqClnqEQhfgHJJ5QF0R5A==" + }, + "domhandler": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.0.tgz", + "integrity": "sha512-fC0aXNQXqKSFTr2wDNZDhsEYjCiYsDWl3D01kwt25hm1YIPyDGHvvi3rw+PLqHAl/m71MaiF7d5zvBr0p5UB2g==", + "requires": { + "domelementtype": "^2.2.0" + } + }, + "domutils": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", + "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", + "requires": { + "dom-serializer": "^1.0.1", + "domelementtype": "^2.2.0", + "domhandler": "^4.2.0" + } + }, + "entities": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", + "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==" + }, + "follow-redirects": { + "version": "1.14.7", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.14.7.tgz", + "integrity": "sha512-+hbxoLbFMbRKDwohX8GkTataGqO6Jb7jGwpAlwgy2bIz25XtRm7KEzJM76R1WiNT5SwZkX4Y75SwBolkpmE7iQ==" + }, + "htmlparser2": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-6.1.0.tgz", + "integrity": "sha512-gyyPk6rgonLFEDGoeRgQNaEUvdJ4ktTmmUh/h2t7s+M8oPpIPxgNACWa+6ESR57kXstwqPiCut0V8NRpcwgU7A==", + "requires": { + "domelementtype": "^2.0.1", + "domhandler": "^4.0.0", + "domutils": "^2.5.2", + "entities": "^2.0.0" + } + }, + "nth-check": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-2.0.1.tgz", + "integrity": "sha512-it1vE95zF6dTT9lBsYbxvqh0Soy4SPowchj0UBGj/V6cTPnXXtQOPUbhZ6CmGzAD/rW22LQK6E96pcdJXk4A4w==", + "requires": { + "boolbase": "^1.0.0" + } + }, + "parse5": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-6.0.1.tgz", + "integrity": "sha512-Ofn/CTFzRGTTxwpNEs9PP93gXShHcTq255nzRYSKe8AkVpZY7e1fpmTfOyoIvjP5HG7Z2ZM7VS9PPhQGW2pOpw==" + }, + "parse5-htmlparser2-tree-adapter": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/parse5-htmlparser2-tree-adapter/-/parse5-htmlparser2-tree-adapter-6.0.1.tgz", + "integrity": "sha512-qPuWvbLgvDGilKc5BoicRovlT4MtYT6JfJyBOMDsKoiT+GiuP5qyrPCnR9HcPECIJJmZh5jRndyNThnhhb/vlA==", + "requires": { + "parse5": "^6.0.1" + } + }, + "prompt-sync": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/prompt-sync/-/prompt-sync-4.2.0.tgz", + "integrity": "sha512-BuEzzc5zptP5LsgV5MZETjDaKSWfchl5U9Luiu8SKp7iZWD5tZalOxvNcZRwv+d2phNFr8xlbxmFNcRKfJOzJw==", + "requires": { + "strip-ansi": "^5.0.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "requires": { + "ansi-regex": "^4.1.0" + } + }, + "tslib": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.3.1.tgz", + "integrity": "sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw==" + } + } +} diff --git a/JavaScript/GetCovid19Statistics/package.json b/JavaScript/GetCovid19Statistics/package.json new file mode 100644 index 000000000..a179a9975 --- /dev/null +++ b/JavaScript/GetCovid19Statistics/package.json @@ -0,0 +1,16 @@ +{ + "name": "getcovid19stats", + "version": "1.0.0", + "description": "", + "main": "index.js", + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1" + }, + "keywords": [], + "author": "", + "license": "ISC", + "dependencies": { + "covid19-stats": "^1.1.3", + "prompt-sync": "4.2.0" + } +} \ No newline at end of file From a3e4cadc4def8f8ccde7cc92e5f320efc418ad9c Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Sun, 27 Mar 2022 03:24:55 +0530 Subject: [PATCH 13/18] Update README.md --- JavaScript/GetCovid19Statistics/README.md | 30 ++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/JavaScript/GetCovid19Statistics/README.md b/JavaScript/GetCovid19Statistics/README.md index 22f4410c4..3b1fd1881 100644 --- a/JavaScript/GetCovid19Statistics/README.md +++ b/JavaScript/GetCovid19Statistics/README.md @@ -1 +1,29 @@ -## Script to retrieve COVID-19 stats using country name +# Script to retrieve COVID-19 stats using country name +## Description +The script provides live Covid-19 statistics of a country by using "covid19-stats", an NPM module to retrieve worldometer's live Covid-19 stats. The module uses web scraping to obtain real time access to world wide statistical information. Using this script, you can provide the country name as input and get a JsonArray containing latest statistics of the desired country (as listed in worldometers) such as: country, totalCases, newCases, totalDeaths and newDeaths. + +## Inputs + +**country *Text*** + +Country name as text input. + + +## Outputs + +**covid19StatsReport *JsonArray*** + +Covid-19 statistics report as per the country provided as input. + +# Usage + +- Clone the folder. +- Open command line and change the directory to your folder by using `cd foldername` +- Run the command `npm intall` to import all required modules. +- If you still face module import error, try using `npm install package-name` to install missing modules. +- then run the script by using the command `node index.js`. + +this script is meant for educational purposes only. + +# Demo +![Screenshot (330)](https://user-images.githubusercontent.com/80174214/160258324-d09bb350-6cc5-4f41-bead-6e9dbf5373f5.png) From 2464e0f0cd60d3aca65080826cadc81735e1f7c7 Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Sun, 27 Mar 2022 18:44:49 +0530 Subject: [PATCH 14/18] Update README.md --- JavaScript/GetCovid19Statistics/README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/JavaScript/GetCovid19Statistics/README.md b/JavaScript/GetCovid19Statistics/README.md index 3b1fd1881..61e4b5db6 100644 --- a/JavaScript/GetCovid19Statistics/README.md +++ b/JavaScript/GetCovid19Statistics/README.md @@ -21,9 +21,9 @@ Covid-19 statistics report as per the country provided as input. - Open command line and change the directory to your folder by using `cd foldername` - Run the command `npm intall` to import all required modules. - If you still face module import error, try using `npm install package-name` to install missing modules. -- then run the script by using the command `node index.js`. +- Then, run the script by using the command `node index.js`. -this script is meant for educational purposes only. +This script is meant for educational purposes only. # Demo -![Screenshot (330)](https://user-images.githubusercontent.com/80174214/160258324-d09bb350-6cc5-4f41-bead-6e9dbf5373f5.png) +[![160258324-d09bb350-6cc5-4f41-bead-6e9dbf5373f5.png](https://i.postimg.cc/VLRdw0f6/160258324-d09bb350-6cc5-4f41-bead-6e9dbf5373f5.png)](https://postimg.cc/crvsMH8y) From 1de6e31c0958dbf26401275c5e6a22c2ef8a2297 Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Sun, 27 Mar 2022 18:47:31 +0530 Subject: [PATCH 15/18] Rename JavaScript/GetCovid19Statistics/README.md to JavaScript/Get_Covid19_Statistics/README.md --- .../{GetCovid19Statistics => Get_Covid19_Statistics}/README.md | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename JavaScript/{GetCovid19Statistics => Get_Covid19_Statistics}/README.md (100%) diff --git a/JavaScript/GetCovid19Statistics/README.md b/JavaScript/Get_Covid19_Statistics/README.md similarity index 100% rename from JavaScript/GetCovid19Statistics/README.md rename to JavaScript/Get_Covid19_Statistics/README.md From 5de1d4ab1fcbaf2240f3a96efde8fb67b5114b9a Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Sun, 27 Mar 2022 18:49:27 +0530 Subject: [PATCH 16/18] Update and rename JavaScript/GetCovid19Statistics/index.js to JavaScript/Get_Covid19_Statistics/index.js --- .../{GetCovid19Statistics => Get_Covid19_Statistics}/index.js | 1 - 1 file changed, 1 deletion(-) rename JavaScript/{GetCovid19Statistics => Get_Covid19_Statistics}/index.js (96%) diff --git a/JavaScript/GetCovid19Statistics/index.js b/JavaScript/Get_Covid19_Statistics/index.js similarity index 96% rename from JavaScript/GetCovid19Statistics/index.js rename to JavaScript/Get_Covid19_Statistics/index.js index b8fc61fb6..ee6b3459b 100644 --- a/JavaScript/GetCovid19Statistics/index.js +++ b/JavaScript/Get_Covid19_Statistics/index.js @@ -8,4 +8,3 @@ async function main() { } module.exports.main = main main(); - From dedf55e8de674a27b456c4888c21a6aa33a691b3 Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Sun, 27 Mar 2022 18:50:05 +0530 Subject: [PATCH 17/18] Rename JavaScript/GetCovid19Statistics/package-lock.json to JavaScript/Get_Covid19_Statistics/package-lock.json --- .../package-lock.json | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename JavaScript/{GetCovid19Statistics => Get_Covid19_Statistics}/package-lock.json (100%) diff --git a/JavaScript/GetCovid19Statistics/package-lock.json b/JavaScript/Get_Covid19_Statistics/package-lock.json similarity index 100% rename from JavaScript/GetCovid19Statistics/package-lock.json rename to JavaScript/Get_Covid19_Statistics/package-lock.json From 97060873f7aa70be6743d709dbdfc0aed8dd9b32 Mon Sep 17 00:00:00 2001 From: Abhilipsa Sahoo Date: Sun, 27 Mar 2022 18:50:44 +0530 Subject: [PATCH 18/18] Rename JavaScript/GetCovid19Statistics/package.json to JavaScript/Get_Covid19_Statistics/package.json --- .../package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) rename JavaScript/{GetCovid19Statistics => Get_Covid19_Statistics}/package.json (94%) diff --git a/JavaScript/GetCovid19Statistics/package.json b/JavaScript/Get_Covid19_Statistics/package.json similarity index 94% rename from JavaScript/GetCovid19Statistics/package.json rename to JavaScript/Get_Covid19_Statistics/package.json index a179a9975..32658d48e 100644 --- a/JavaScript/GetCovid19Statistics/package.json +++ b/JavaScript/Get_Covid19_Statistics/package.json @@ -13,4 +13,4 @@ "covid19-stats": "^1.1.3", "prompt-sync": "4.2.0" } -} \ No newline at end of file +}