This is a Flutter-based E-Commerce Application that allows users to browse products, add them to the cart, checkout, and manage their profile. It also includes dark mode, authentication, and state management using GetX.
- 🏠 Home Screen: Displays products fetched from the backend.
- 🛒 Cart: Add, remove, and update product quantities.
- 🛍️ Order History: View past orders.
- 👤 Profile Management: Edit user details.
- 🔑 Authentication: User login/logout using token-based authentication.
- Flutter (Dart)
- GetX (State Management)
- Node.js & Express (Backend API)
- MongoDB (Database)
- Shared Preferences (Local Storage for Auth Tokens)
git clone https://github.com/your-repo/ecommerce-app.git
cd ecommerce-app
flutter pub get
For Android Emulator:
flutter run
For Web:
flutter run -d chrome
The app fetches data from a Node.js API. Change the base URL in the API requests if needed:
const BASE_URL = 'http://10.0.2.2:3000/api/';
📦 ecommerce-app
┣ 📂 lib
┃ ┣ 📂 controllers # State management using GetX
┃ ┣ 📂 models # Data models
┃ ┣ 📂 screens # UI Screens (Home, Cart, Profile, etc.)
┃ ┗ main.dart # Main entry point
- Image Not Loading?
- Ensure your backend is running (
npm start
if using Node.js). - Replace
localhost
with10.0.2.2
for Android Emulator.
- Ensure your backend is running (
- Login Issues?
- Check if the correct token is stored in Shared Preferences.
This project is for educational purposes. Feel free to modify and expand.
For any queries, reach out at [your-email@example.com] or GitHub Profile.