Skip to content

czabaj/check.beer-re

Repository files navigation

check.beer

A web application for managing a garage pub. It solves the following problems:

  • which keg is on which tap,
  • how much beer is left in the tapped kegs,
  • how many kegs are there in the storage and who bough them,
  • who is currently present and how many beers they consumed,
  • accounting between keg investors and consumers concerning the net consumption from the keg. Say the keg of 100 beers costs 1000 credits, then one beer should cost 10 credits but there are always wastes, in reality, only around 95 beers are drafted and this app divides the net consumption between consumers.

See for your selves on check.beer

History

This app originates from an Android application "BeerBook", which I made years ago and never released publicly. It serves well for its users, although it has a few drawbacks, most notably no cloud backup 🧨

Developer facts of interest

  • this app is written in ReScript, a flavor of OCaml programming language which compiles to clean JavaScript,
  • this app is a progressive-web-app (PWA), it can be installed as a standalone app and is capable of running offline with almost no limitations,
  • this app runs on Firebase and utilizes most of its goodies - offline support, near real-time synchronization, low-cost operation and super reliability,
  • this app is written in React using Suspense for data-fetching, RxJS is used to construct data-pipes for React components,
  • this app uses vanilla CSS for styling with an emphasis on modern CSS features, like Colors Module 4, Logical Properties, Subgrid or Anchor Positioning, using modern layouts to eschew screen-width media queries as much as possible,
  • appropriate HTML elements are used concerning accessibility (A11Y), the HTML structure is always shallow, no extra <div> ever,
  • modern HTML elements are used, like <dialog> or <details>,
  • modern browser APIs are used, like Intl API, bleeding-edge Popover API or View Transition API,
  • the app implements Web Authentication API (WebAuthn) protocol which allows password-less login on devices with biometric authenticators 🐾

There is no UI framework employed nor many libraries, I aim at replacing them with modern native Web APIs. Expect instability, but if you want to learn more about PWA and the modern Web, you are in the right place 🤗

GitHub Issues welcomed 🙇‍♂️