This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| CSS Reset inspired from Josh's version at | |
| https://www.joshwcomeau.com/css/custom-css-reset/ | |
| */ | |
| /* 1. Use a more-intuitive box-sizing model */ | |
| *, | |
| *::before, | |
| *::after { | |
| box-sizing: border-box; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| v1.0.x | |
| NPM Package: npm install countrypppdata | |
| */ | |
| const axios = require("axios"); | |
| const { getCodes, getCodeList } = require("country-list"); | |
| async function fetchCountryData() { | |
| let countries = getCodes(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const merge = function (arr1, arr2) { | |
| let output = []; | |
| let target; | |
| while (true) { | |
| if (arr1.length == 0 && arr2.length == 0) break; | |
| else if (arr1.length == 0 && arr2.length != 0) target = arr2; | |
| else if (arr1.length != 0 && arr2.length == 0) target = arr1; | |
| else { | |
| if (arr1[0] > arr2[0]) target = arr2; | |
| else target = arr1; |