Thanks to visit codestin.com
Credit goes to github.com

Skip to content

founder-pl/form

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

35 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Multi-Country Tax & Cost of Living Comparison Tool

Tax Comparison Tool Screenshot

A comprehensive web application for comparing tax, benefits, and cost of living across multiple countries. This tool helps individuals, digital nomads, and businesses understand their financial obligations and lifestyle costs in different jurisdictions.

✨ Features

  • Multi-Country Comparison: Compare tax scenarios across multiple countries simultaneously
  • Business Support: Support for various business types (production, trade, services, freelance, e-commerce)
  • Family Benefits: Calculate family and children benefits (500+, 800+, Kindergeld, etc.)
  • Cost of Living: Detailed cost of living comparisons across cities
  • Custom Scenarios: Create and save custom business and family scenarios
  • Interactive Visualizations: Charts and graphs for easy comparison
  • Responsive Design: Works on desktop and mobile devices
  • REST API: Programmatic access to tax and cost calculations
  • CLI Interface: Command-line interface for quick calculations

πŸš€ Getting Started

Prerequisites

  • Node.js 18+ (LTS recommended)
  • npm or yarn
  • Git

Installation

  1. Clone the repository:

    git clone https://github.com/yourusername/tax-comparison-tool.git
    cd tax-comparison-tool
  2. Install dependencies:

    npm install
  3. Start the development server:

    npm run dev
  4. Open http://localhost:3000 in your browser

πŸ—οΈ Project Structure

tax-comparison-tool/
β”œβ”€β”€ src/                    # Source code
β”‚   β”œβ”€β”€ components/         # React components
β”‚   β”œβ”€β”€ contexts/           # React contexts
β”‚   β”œβ”€β”€ pages/              # Page components
β”‚   β”œβ”€β”€ services/           # Business logic and API clients
β”‚   β”œβ”€β”€ utils/              # Utility functions
β”‚   └── __tests__/          # Test files
β”œβ”€β”€ public/                 # Static files
β”œβ”€β”€ data/                   # Data files
β”‚   β”œβ”€β”€ countries/          # Country-specific data
β”‚   β”œβ”€β”€ benefits.json       # Benefits data
β”‚   └── cost-of-living/     # Cost of living data
β”œβ”€β”€ scripts/                # Utility scripts
β”œβ”€β”€ .github/                # GitHub configurations
β”œβ”€β”€ .vscode/                # VS Code settings
β”œβ”€β”€ dist/                   # Build output
β”œβ”€β”€ coverage/               # Test coverage reports
└── docs/                   # Documentation

πŸ› οΈ Services

Key services in the application:

  • Benefit Calculator: Handles calculation of various benefits
  • Data Service: Manages loading and accessing country data
  • Tax Calculator: Core tax calculation logic

πŸ“Š Data Structure

The application uses a modular data structure with separate files for different aspects:

  • Country-specific data in data/countries/
  • Benefits configuration in data/benefits.json
  • Cost of living data in data/cost-of-living/

πŸ§ͺ Testing

Run tests using the following commands:

# Run all tests
npm test

# Run specific test suites
npm run test:unit    # Unit tests
npm run test:api     # API tests
npm run test:cli     # CLI tests

🀝 Contributing

Contributions are welcome! Please see our Contributing Guidelines for details.

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details. β”‚ β”‚ β”œβ”€β”€ eventHandlers.js β”‚ β”‚ β”œβ”€β”€ tableUpdater.js β”‚ β”‚ β”œβ”€β”€ taxCalculator.js β”‚ β”‚ └── templateLoader.js β”‚ └── app.js # Main application entry point β”œβ”€β”€ index.html # Main HTML file └── README.md # This file


## Getting Started

1. **Prerequisites**
   - Modern web browser (Chrome, Firefox, Safari, Edge)
   - Node.js (for development)

2. **Installation**
   ```bash
   # Clone the repository
   git clone https://github.com/founder-pl/form.git
   cd form
   
   # Install dependencies (if any)
   npm install
   
   # Start development server (if configured)
   npm run dev
  1. Usage
    • Open index.html in your web browser
    • Select countries to compare
    • Enter your financial and personal details
    • View and compare tax scenarios

Data Model

The application uses the following main data structures:

Country Data

{
  "PL": {
    "name": "Poland",
    "flag": "πŸ‡΅πŸ‡±",
    "eu": true,
    "vat": 23,
    "taxIncome": {
      "production": 19,
      "trade": 19,
      "services": 19,
      "freelance": 12,
      "ecommerce": 19
    },
    "socialSecurity": 1500,
    "notes": "Additional country-specific notes"
  }
}

Family Data

{
  "maritalStatus": "single",
  "spouseLocation": "PL",
  "unemploymentStatus": "none",
  "children": [
    {
      "name": "Anna",
      "age": 5,
      "isNewborn": false,
      "isStudent": false,
      "isDisabled": false
    }
  ]
}

Extension Points

The application is designed to be extensible. Here are the main extension points:

  1. Adding New Countries

    • Add country data to data/countries.json
    • Add benefit information to data/benefits.json
  2. Custom Tax Calculations

    • Implement custom tax logic in taxCalculator.js
    • Use the getCustomTaxCalculation hook for country-specific rules
  3. Additional Benefits

    • Add new benefit types in benefitCalculator.js
    • Update the UI components to display new benefit types

Development

Building

# Build for production
npm run build

Testing

# Run tests
npm test

Code Style

License

This project is licensed under the MIT License - see the LICENSE file for details.

Acknowledgments

  • Bootstrap 5 for responsive design
  • Font Awesome for icons
  • All contributors who helped improve this tool

Roadmap

  • Add more countries and regions
  • Implement more detailed tax calculations
  • Add support for historical tax rates
  • Create user accounts for saving scenarios
  • Add more visualization options (charts, graphs)
  • Improve mobile experience
  • Add more documentation and examples

Releases

No releases published

Packages

No packages published

Languages