Git Product home page Git Product logo

oxcened / my-order Goto Github PK

View Code? Open in Web Editor NEW
32.0 32.0 9.0 1.33 MB

A React application designed for group food order tracking, enabling users to export daily summaries to Google Sheets.

Home Page: https://medium.com/@alen.ajam/how-i-took-control-of-my-companys-lunchtime-with-an-app-f6d70c31cb89

License: MIT License

JavaScript 0.84% TypeScript 96.67% SCSS 1.55% CSS 0.58% HTML 0.36%
css firebase react tailwindcss typescript vitejs

my-order's Introduction

Hey there ๐Ÿ‘‹

I'm Alen, 24 years old Software Engineer based in Italy.

Right now, I'm actively getting more involved in the open source community.

Feel free to get in touch for anything related to collaborations, projects, volunteering or just to have a chat!

alenajam.dev | [email protected]


Cool stuff that I contributed to:

my-order's People

Contributors

alexsp84 avatar dependabot[bot] avatar oxcened avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

my-order's Issues

Migration to Vite

The issue

The app was initially a project of mine developed for the sake of getting my hands on Gatsby.
However it later became a more serious project as it was something we actually started using in my company.
At one time I understood Gatsby was not the best choice for this useโ€“case as it makes some parts of the development painful while not giving any extra benefit to this particular project.

Solution

I'm going to migrate the app to a Single Page App which is going to use Vite.js.
Build times will be a whole lot better and the code will be a bit leaner by removing all of the Gatsby related stuff.

Refactor modules

Modules (./src/modules) need to be refactored.
We moved from a role-based architecture to a feature-driven one in #5.
However, since that wasn't the main focus of that PR, modules implementation is not really complete.

Those two principles are important when it comes to modules:

  • Low coupling: it means that modules should be as independent as possible from one another, so that changes to one module have zero or minimal impact on other modules. Modules shouldn't have knowledge of the inner workings of other modules.
  • High cohesion: it means that modules should comprise a collection of code that acts as a system. They should have clearly defined responsibilities and stay within boundaries of certain domain knowledge. Consider a sample ebook application. It might be inappropriate to mix book and payment related code together in the same module as they are two different functional domains.

Currently, modules are not properly isolated and any module can and does access any file of any other module with no strategy in mind.

So to work on this, the idea is to:

  • implement an index.js file at the root of each module that
  • only export the entities of the module that are meant to be public
  • everything else should not be exported and not used in any other module
  • the index.js file formally acts as the public interface of the module
  • a module should exclusively interact with another module through its public interface
  • keep in mind that, as JavaScript doesn't really offer a way to tweak the export and imports of modules, we don't have a way to enforce the rule that any other file outside of index.js is not allowed to be imported

EDIT: as for the last point, you can actually do that with npm packages, but for now I'm going to keep things simple.

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.