Git Product home page Git Product logo

race-betting-app's Introduction

react typescript cra eslint prettier mui router lodash swr

Race betting app

Usage

Demo

See demo hosted there

Local

Running application:

  • Clone repo
  • cd race-betting-app
  • yarn install
  • yarn start

App built with node v16.13.2 (current LTS)

Roadmap

  • Race screen is totally uncontrolled (inputs are not saved), they need to be stored in the app's state
  • user can place bet with multiple winners etc., he should be able to choose just one winner etc.
  • Bet button should be disabled until user chooses his bet for first, second and third place
  • rethink and re-do caching/persistance approach

Notes

App state persistence

Application uses react-router to navigate to different screens, therefore refreshing will navigate to same screen.
Application uses swr (cahed in local-storage) for stale-while-revalidate approach:

  • what it does: uses stale values when saved
  • what it should do: use stale values and display them to user, but revalidate to present new ones
  • why it does what it does and not what it should do: we use https://my-json-server.typicode.com/hdjfye/bet-api, no need to overload it with unecessary queries for demo app

Hash router

Used because it doesn't generate as many problems as normal when hosting on github pages

race-betting-app's People

Contributors

arkadiuszpasek 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.