Skip to content

About

Assignment 2 - Advanced Website based on Modern Frontend Libraries

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

8 Commits

Folders and files

Repository files navigation

Smart Expense Tracker

An expense tracker that uses smart text parsing to add transactions quickly.

1. Problem Summary

Tracking money usually means filling out long forms with dates, amounts, categories, and titles. This app tries to fix that by letting you just type what happened, like "spent 15 on lunch" or "earned 50 from selling books". It figures out the amount, title, and whether it's an income or expense automatically. It also gives you a dashboard to search through everything.

2. Technical Stack

  • Frontend: React
  • Styling: Tailwind CSS
  • Backend: Node.js / Express
  • Database: SQLite
  • Authentication: JWT + bcrypt

3. Feature List

  • Smart Text Parsing: Type a sentence and the app will extract the transaction details (currency symbols/words are cleanly filtered out).
  • User Authentication: Sign up and log in securely.
  • Live Real-Time Search: Search your transactions instantly as you type.
  • Role-Based Admin Dashboard:
    • Dedicated Admin View: Admin users (Login: admin / Password: admin) are automatically routed to a secure dashboard and isolated from normal personal finance views.
    • User Search & Management: Quickly search for registered users by name and delete accounts if necessary.
    • User Detail Drill-down: Click on any user to view their specific activity logs and personal transaction history.

4. Folder Structure

project-root/
|-- server/
|   |-- database.sqlite    # The SQLite database file
|   |-- server.js          # The Express API backend
|   |-- .env               # Environment variables (you need to create this)
|   |-- package.json       # Backend dependencies
|-- src/
|   |-- components/        # React components (Dashboard, AdminPanel, Auth, etc.)
|   |-- App.jsx            # Main React application
|   |-- index.css          # Tailwind CSS styles
|   |-- main.jsx           # React entry point
|-- index.html             # Main HTML file
|-- package.json           # Frontend dependencies
|-- tailwind.config.js     # Tailwind configuration
|-- vite.config.js         # Vite configuration

How to Run

  1. Open your terminal and navigate to the server folder, then run:
    npm install
  2. Important: Create a file named .env inside the server folder and paste this exact line into it:
    JWT_SECRET=assignment2_super_secret
    (This is required because the file is ignored by Git for security).
  3. Start the backend server by running:
    node server.js
  4. Open a new terminal window, navigate to the root project folder (not the server folder), and run:
    npm install
    npm run dev
  5. Click the local link provided by Vite (usually http://localhost:5173) to open the app.

About

Assignment 2 - Advanced Website based on Modern Frontend Libraries

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages