Giter VIP home page Giter VIP logo

starwars's Introduction

Questions

Assuming the Star Wars API was slow, what are some optimizations that could be implemented to improve the user experience?

I faced this problem when I found out that the API did not have a full call therefore whenever loading films, it would take a long time to load. To get around this, I implemented a lazy loader (pagination, load spinners would all work too) on the sections that required additional api calls. This reduced the load time greatly but it required the user to wait to see the data which may not be good user experience. A solution I consider was using Redis (in-memory data structure store) and storing all the data in memory. Afterwards I would set up a set interval task to call all the api's data in the background so the data stays up to date. I decided against it since I felt it was a bit over the top for the scope of the project.

Any improvements you would make to your application?

I would make a pull request to the repo so users can make full api calls. This would reduce a lot of the problems that I have. I could have made a more elegant solution to check for bad data in the hash I was receiving from my API Helper. Something interesting would to make a more comprehensive search function that searches for everything instead of films.

Note: The api on the sheet says 'https://swapi.com' but when visiting the site, it is just a parked domain. I assumed either the site got moved or this url was a typo. The working url is 'https://swapi.co'. I thought it was worth mentioning in case future applicants faced similar problems.

starwars's People

Contributors

pingchangwu avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.