Author: IsaacRF239
Deployed app URL: https://isaacrf.com/apps/github-ngsearch
License: GNU GPLv3
Angular test app that consumes GitHub API to retrieve data. This project was generated with Angular CLI version 9.1.7.
Production app can be accesed on http://isaacrf.com/apps/github-ngsearch
Use the search bar to search for users by their login name. The search is performed as you type
Theme button can be used to dinamically swap themes
Click an user to go to the user details
Layout is adapted to be well visualized in any resolution.
App is ready for mobile resolution and navigation transitions are animated.
This app caches the user details once retrieved, and this data has a configurable lifetime, setted to 1 hour by default. GitHub API is called in every navigation to user detail, however, succesive calls are filled with an Etag header field GitHub uses to determine if data has changed since the last call. If not, GitHub API just return a 304, not modified error, and data is then retrieved from cache.
Calls with a 304 error don't count towards API call limits, and since they return empty, they are also fast in most case scenarios.
An optional timeout and offline cache could be also implemented to avoid sucessive calls for a period of time, but that's out of the scope of this project.
User detail page is configured to lazy load only when it's required, helping keep initial bundle sizes smaller, which in turn helps decrease load times. As user search module is the main route point of the app and it's required on first load most of the time, I opted to go with an eagerly load approach, also serving as demonstration purposes showing the differences between the two modes.
App architecture is structured so the app is fully and easily scalable in the future, using the core module, shared modules, and module by feature division philosophy.
App is built and tested on every branch push, and development and master branches are protected expecting this build and test process to pass before any pull request can be accepted and merged. Development and Master also launch the build and test process to ensure everything is ok after every merge. This encloses a secured continuous integration workflow.
Run ng serve --open
for a dev server. The app will automatically reload if you change any of the source files.
Run ng build --prod --base-href ./
to build the project production ready. The build artifacts will be stored in the dist/
directory.
This project uses a GNU General Public License v3.0. This means that:
- You can freely use, copy, modify and redistribute this software, as long as it remains open source.
- You must keep original copyright information and notices. Removing them is not permitted.
- If you modify and / o redistribute this code, you must use the same license (GNU General Public License v3.0).