Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ahmedbhameed/coffee-test
Get drunk with coffee challenge ;)
https://github.com/ahmedbhameed/coffee-test
Last synced: 10 days ago
JSON representation
Get drunk with coffee challenge ;)
- Host: GitHub
- URL: https://github.com/ahmedbhameed/coffee-test
- Owner: AhmedBHameed
- License: mit
- Created: 2019-09-18T22:12:12.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2022-12-10T03:05:05.000Z (almost 2 years ago)
- Last Synced: 2024-10-12T02:10:48.152Z (26 days ago)
- Language: JavaScript
- Homepage: https://kakiee.at/coffee-challenge/
- Size: 6.58 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 12
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Drunk with Coffee game
Simple game for demonstration. [Play now](https://kakiee.at/coffee-challenge/)
![game demo](./src/assets/coffee_game.gif)
# Installation
- `git clone https://github.com/AhmedBHameed/coffee-test`
- `npm install` OR `yarn`
- `yarn start`## What's included
- Bundling with parcel
- Dev server with hot module replacement
- React 16
- styled-components## Usage
Drink as much coffee as you can without overflow it. Till you get drunk with good stuff of coffee ;)
## Build
- `npm run build` OR `yarn build` but note for the files change in dist. PWA is caching static files which may change with hash part.
## Some hurdles
- I can see the app is using `parcel` which causing error on console on `build`. I would suggest to apply the game with the newest React boiler plate since they use either `babel` or `typescript` or other task bundler which are at least better than `parcel` i believe like `rollup`.
- Since i'm new to PWA, I did a basic programming part related. Hope that it will work on your side as it worked on mine. PWA is a big topic and i believe there are many parts in the code can be handel in a better way.
- Regarding to the game itself, I would do some refactoring parts for the components. But since the test did not say about performance, i just make it work and functional.
What i mean by performance is that the timer for example is applied for all cups which is using render for each cup component. As a feature step for the app i can move up the timer to the parent component and handel it with events when needed.- If you see some difference in `package.json` that comes from try and error using parcel bundler to see where the problem of the error code mentioned up comes from. A point of prove about it - you can check other branch `app/webpack` as webpack applied on the application for better bundling options and structure but it is not complete.