{"id":18331185,"url":"https://github.com/bankole2000/githubfinder","last_synced_at":"2025-04-09T18:13:02.277Z","repository":{"id":109352515,"uuid":"182605275","full_name":"Bankole2000/githubfinder","owner":"Bankole2000","description":"Simple Application to search for Github users by username","archived":false,"fork":false,"pushed_at":"2019-04-23T11:48:55.000Z","size":30,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-04-09T18:12:59.067Z","etag":null,"topics":["async-await","es6-classes","fetch-api","github-api","promises"],"latest_commit_sha":null,"homepage":"https://bankole2000.github.io/githubfinder/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Bankole2000.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-04-22T01:56:56.000Z","updated_at":"2019-04-26T23:57:01.000Z","dependencies_parsed_at":"2023-03-25T14:35:30.767Z","dependency_job_id":null,"html_url":"https://github.com/Bankole2000/githubfinder","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Bankole2000%2Fgithubfinder","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Bankole2000%2Fgithubfinder/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Bankole2000%2Fgithubfinder/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Bankole2000%2Fgithubfinder/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Bankole2000","download_url":"https://codeload.github.com/Bankole2000/githubfinder/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248085327,"owners_count":21045139,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["async-await","es6-classes","fetch-api","github-api","promises"],"created_at":"2024-11-05T19:28:36.133Z","updated_at":"2025-04-09T18:13:02.254Z","avatar_url":"https://github.com/Bankole2000.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# GitHub Finder\n\nJS Application to fetch github user data - [View Demo](https://bankole2000.github.io/githubfinder)\n\n[![Practice](https://img.shields.io/badge/Practice-JavaScript-yellow.svg)](https://bankole2000.github.io/githubfinder)\n\n_\u003cp align=\"center\"\u003e\"I continue to push on... Longing to Master the Ways of JavaScript Ninjutsu\"\u003c/p\u003e_\n\n\u003cdiv align=\"center\" style=\"text-align:center; margin:auto;\"\u003e\n\u003cimg align=\"center\" src=\"https://i.imgur.com/SeUttrI.png\" width=\"150\"/\u003e\n\u003c/div\u003e\n\n## What it is\n\nAn simple, well-commented, learning oriented, single page JS demo Project to practice ES6 programming concepts, using `fetch API, Primses, async await` (all that good stuff) and `github API`. Built with:\n\n- HTML\n- Vanilla JS - ES6\n- [Bootswatch CSS](http://www.bootswatch.com/) - A Bootstrap based CSS Theming tool\n- [Github API](https://api.github.com/users/) - You're all there yo.\n- [Awesomeness](https://www.wikihow.com/Love-Programming) - Strictly for the love of coding _Mehn!_\n\n## What it does\n\n- Finds Users on Keyup Event\n- Manipulates DOM to display User Data\n- Links Back to User Page\n- Retreives and displays latest User Repos\n- Link Back to Repos and Home Pages (if available)\n\n## Learning Points\n\n- ES6 Classes\n- Fetch API\n- Promises\n- Async Await\n- Iternary and Template Strings\n- DOM Manipulation \u0026 Traversal\n- Event Handing \u0026 Delegation\n- Creating \u0026 Appending Elements\n- A lil Bootstrap 4 syntax n Alerts\n\n## Some cool stuff\n\nI think its **_So Cool_** that you can make multiple requests using `async await` in a single function. (a method actually, of the `Github()` made in the `github.js` file). Much better (and imho more _reliable_ than ES5 callbacks/Ajax):\n\n```javascript\nasync getUser(user) {\n    const profileResponse = await fetch(\n      `https://api.github.com/users/${user}?client_id=${\n        this.client_id\n      }\u0026client_secret=${this.client_secret}`\n    );\n\n    const repoResponse = await fetch(\n      `https://api.github.com/users/${user}/repos?per_page=${\n        this.repos_count\n      }\u0026sort=${this.repos_sort}\u0026client_id=${this.client_id}\u0026client_secret=${\n        this.client_secret\n      }`\n    );\n\n    const profile = await profileResponse.json();\n    const repos = await repoResponse.json();\n\n    return {\n      profile,\n      repos\n    };\n  }\n```\n\nAlso, perhaps I wasn't doing it properly, but I had issues with using the `iternary operator` within the `string literal`, for the Homepage Links (in the repo object `forEach()` loop). So a work around I did was this:\n\n```javascript\nlet a = `\u003ca href='${repo.homepage}' target=\"_blank\"\u003e View Demo \u003c/a\u003e`,\n  b = `Null`;\n`Homepage: ${repo.homepage ? a : b}`; // in the loop\n```\n\n\u003e Also (Just a thought), this is probably how [Sourcer.io](https://sourcerer.io) Works... pretty cool.\n\n## Features in Development\n\nNaaa... This is just about done and dusted far as I'm concerned, lol ^-^\n\n## Contribution\n\nContributions are highly welcome. Feel free to fork, clone, make pull requests, report issues etc.\n\n## Acknowledgments\n\n- Many thanks to [@bradtraversy](https://github.com/bradtraversy) for his awesome courses - _i will not fail you sensei_\n- Thanks to [@torvalds](https://github.com/torvalds) For Making the world a better place\n- And To anyone reading this... _You're awesome!_\n\nThat being said\n_\u003cp align=\"center\"\u003eAdieu, Till I push again... I must return to my meditations on the Ways of JS Ninjustu\u003c/p\u003e_\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbankole2000%2Fgithubfinder","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbankole2000%2Fgithubfinder","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbankole2000%2Fgithubfinder/lists"}