A React application that calculates your net take-home salary based on your gross income and selected pay period, using the 2023 U.S. federal and state income tax brackets.
Check out the app here
- Features
- Getting Started
- Build for Production
- Deployment
- Technology Stack
- Tax Information
- Screenshot
- Contributing
- License
- Contact
- Real-time Calculations: Automatically calculates net income as you type.
- Period Selection: Choose from daily, weekly, bi-weekly, monthly, or yearly pay periods.
- Tax Breakdown: Provides a detailed breakdown of federal and state taxes for each tax bracket.
- Currency Formatting: Input and displayed amounts are formatted as currency with proper localization.
- Dark Mode Support: Toggle between light and dark themes with a convenient switch.
- Node.js (version 14 or higher)
- npm (comes with Node.js)
- Git
-
Clone the Repository
git clone https://github.com/ironfruit/NetTakeHome.git cd NetTakeHome -
Install Dependencies
npm install
Start the development server:
npm run devOpen your browser and navigate to http://localhost:5173 to view the application.
To build the application for production, run:
npm run buildThis will create an optimized production build in the dist folder.
The application is deployed using Netlify. You can view the live version here.
To deploy your own version, follow these steps:
-
Build the Application
Ensure you have a production build ready:
npm run build
-
Create a Netlify Account
If you don't have one already, sign up for a free account at Netlify.
-
Deploy to Netlify
-
Option 1: Use the Netlify CLI
Install the Netlify CLI:
npm install -g netlify-cli
Deploy the site:
netlify deploy --prod
Follow the prompts to link the site to your Netlify account and deploy the
distfolder. -
Option 2: Connect via GitHub
- Push your project to a GitHub repository.
- In Netlify, click on "New site from Git."
- Connect your GitHub account and select the repository.
- Set the build command to
npm run buildand the publish directory todist. - Click "Deploy Site."
-
-
Configure Build Settings
Ensure your build settings in Netlify are:
- Build Command:
npm run build - Publish Directory:
dist
- Build Command:
-
Access Your Deployed Site
After deployment, Netlify will provide you with a URL where your application is live.
- React: A JavaScript library for building user interfaces.
- Vite: A fast development build tool.
- Tailwind CSS: A utility-first CSS framework for rapid UI development.
- react-number-format: A library for formatting numbers in React.
The tax calculations include:
- Federal Income Tax: Based on the 2023 U.S. federal income tax brackets for single filers.
- Social Security Tax: 6.2% on wages up to $160,200.
- Medicare Tax: 1.45% on all wages, plus an additional 0.9% on wages over $200,000.
- State Income Tax: Based on the selected state (all 50 states included).
- State Disability Insurance (SDI): Included for applicable states (e.g., California at 1.2%).
References:
Contributions are welcome! Please follow these steps:
-
Fork the Repository
Click on the "Fork" button at the top right of the repository page to create a copy in your GitHub account.
-
Clone Your Fork
git clone https://github.com/yourusername/NetTakeHome.git cd NetTakeHome -
Create a Branch
git checkout -b feature/YourFeatureName
-
Make Your Changes
Implement your feature or bug fix.
-
Commit Your Changes
git add . git commit -m "Add Your Feature"
-
Push to Your Fork
git push origin feature/YourFeatureName
-
Submit a Pull Request
Go to the original repository and click on "Compare & pull request" to submit your changes for review.
This project is licensed under the MIT License.
See the LICENSE file for details.
For any questions or suggestions, feel free to reach out:
- GitHub: ironfruit
- Email: code.wesleyfranks@gmail.com