How ssi-anik/bd-income-tax-calculator works
Project type and purpose
• This is a single-page, client-side React application bootstrapped with Create React App.
• It is intended to run in the browser as a front-end only project (no backend code in this repo).
• Its primary function is to display company, salary, and user information via a set of React components.
File structure
• Top-level files and dirs:
• public/ – static assets (index.html, manifest.json, robots.txt) that get served directly.
• src/ – React source code, including the root index.js and the App component plus subcomponents.
• package.json – lists React, React-DOM and build/deploy scripts.
• .github/workflows/deploy_gh_pages.yml – CI/CD pipeline to build and publish the static site to GitHub Pages.
• No backend directory (e.g., “api” or “server”), so this is purely front-end.
• src/ contains these React components:
• App.js – root container
• TopNav.js – top navigation bar
• LeftSideContent.js / RightSideContent.js – layout columns
• CompanyList.js – list view of companies
• Company.js – individual company details
• SalaryInformation.js – salary detail widget
• UserInformation.js – user profile widget
README for additional insights
• It is a standard Create React App README; there is no extra architecture info.
• The build pipeline uses Webpack/Babel under the hood (hidden until you eject).
a. Main components
• User’s Web Browser (Client)
• Static Hosting / CDN (e.g., GitHub Pages)
• React Single-Page Application
– Entry point: index.html → bundle.js
– Root component: App
– Child components: TopNav, LeftSideContent, RightSideContent, CompanyList, Company, SalaryInformation, UserInformation
• Build Tools (locally): Yarn, Webpack/Babel
b. Relationships and interactions
• User ↔ Browser UI (events, clicks)
• Browser → Static Host (HTTP GET for index.html + JS/CSS bundles)
• React App internal data flow:
– App holds state (e.g., list of companies, selected user)
– Props flow downward from App to children
– Child components emit callbacks/events upward to App to update state
c. Architectural patterns and design principles
• Single-Page Application (SPA)
• Unidirectional data flow (Flux-like)
• Component-based decomposition (container vs. presentational)
• Separation of concerns: static vs. dynamic code, UI vs. build config
d. Key technologies and libraries
• React, ReactDOM
• Webpack, Babel (bundling/transpilation)
• Yarn (package manager)
• GitHub Actions + gh-pages (CI/CD)