Git Product home page Git Product logo

movies-typescript-app's Introduction

How to run the code ?

Explanation of architecture

  • The data comes from the movies.json file in the data folder.

  • MoviesTable component concerns are:

    • Decide on how to process that data
      • What structure of it is relevant (COLUMNS)
      • How to show the data ? (TRANSFORMS)
      • What filters are relevant (FILTERS)
      • What sortings are relevant (SORTS)
        • Those informations are then passed to DataTable component
    • Use a Dialog to show MoviesComments on DataTable row click
  • DataTable component concerns are:

    • Get the data and the COLUMNS, TRANSFORMS, FILTERS and SORTS and process everything in a dynamic data table which is implemented with abstraction, i.e, it is data agnostic, therefore can be used with different data, processing things accorindgly to its props.
    • Performance... one of the properties of it is a CONFIG with the boolean SHOW_ALL_ITEMS. If set to false, it'll care about performance, showing only chunks of data which are increased per scroll.
  • Dialog compoenents concerns are:

    • Show a pop up and its child element
  • MoviesComments concerns are:

    • Connect to the firestore database
    • Get the comments for a specific movie
    • Allow creation of new comments

If you had more time, what would you like to improve?

  • DB config files in .env files
  • Caching the database return for a small period of time to avoid unecessary calls
  • Smooth transitions between components
  • UI tests

FYI

  • Firebase DB connection config was left on a file on purpose
  • The reason is to allow the proper testing of the front-end application without having the need to set up a new firestore database
  • DataTable component is abstract enough in order to make it a npm package in future :)

movies-typescript-app's People

Contributors

reisfmb avatar

Watchers

 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.