Skip to content

UnknownGod2011/LetsCook

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

2 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

LetsCook - AI-Powered Recipe App 🍳

A comprehensive Flutter application that transforms food inspiration into actionable cooking experiences using AI-powered recipe generation, community features, and subscription-based monetization.

✨ Features

πŸ€– AI-Powered Recipe Generation

  • Generate recipes from text descriptions
  • Create recipes from food images
  • YouTube video analysis for recipe extraction
  • Personalized recommendations based on dietary preferences
  • Nutritional analysis and grocery list generation

πŸ‘₯ Community Features

  • Share and discover recipes from other users
  • Like, comment, and save community recipes
  • Follow your favorite cooks
  • Recipe collections and meal planning

πŸ’° Premium Subscription

  • RevenueCat integration for subscription management
  • Premium features with paywall
  • Multiple subscription tiers
  • Restore purchases functionality

🎨 Modern UI/UX

  • Material Design 3 with custom theming
  • Smooth animations and transitions
  • Responsive design for all screen sizes
  • Dark/light theme support
  • Accessibility features

πŸš€ Getting Started

Prerequisites

  • Flutter SDK (>=3.10.7)
  • Dart SDK (>=3.10.7)
  • Android Studio / VS Code
  • Git

Installation

  1. Clone the repository

    git clone https://github.com/yourusername/letscook.git
    cd letscook
  2. Install dependencies

    flutter pub get
  3. Generate code

    flutter packages pub run build_runner build

πŸ”§ Configuration

API Keys Setup

The app requires several API keys for full functionality. You can set them up in multiple ways:

Option 1: Environment Variables (Recommended)

export GEMINI_API_KEY="your_gemini_api_key_here"
export REVENUE_CAT_API_KEY="your_revenue_cat_api_key_here"
export FIREBASE_API_KEY="your_firebase_api_key_here"

Option 2: Flutter Run with --dart-define

flutter run --dart-define=GEMINI_API_KEY=your_key_here \
           --dart-define=REVENUE_CAT_API_KEY=your_key_here \
           --dart-define=FIREBASE_API_KEY=your_key_here

Option 3: Create a .env file (Development only) Create a .env file in the root directory:

GEMINI_API_KEY=your_gemini_api_key_here
REVENUE_CAT_API_KEY=your_revenue_cat_api_key_here
FIREBASE_API_KEY=your_firebase_api_key_here

Required API Keys

  1. Google Gemini AI API Key

  2. RevenueCat API Key

    • Sign up at RevenueCat
    • Create a new project
    • Get your public API key from the dashboard
  3. Firebase API Key (Optional)

    • Create a Firebase project at Firebase Console
    • Enable Authentication
    • Download google-services.json (Android) and GoogleService-Info.plist (iOS)

πŸƒβ€β™‚οΈ Running the App

  1. Development mode

    flutter run
  2. With specific environment

    flutter run --dart-define=ENVIRONMENT=development
  3. Release mode

    flutter run --release

πŸ—οΈ Architecture

The app follows Clean Architecture principles with the following structure:

lib/
β”œβ”€β”€ core/                    # Core utilities and services
β”‚   β”œβ”€β”€ config/             # Environment configuration
β”‚   β”œβ”€β”€ constants/          # App constants
β”‚   β”œβ”€β”€ di/                 # Dependency injection
β”‚   β”œβ”€β”€ error/              # Error handling
β”‚   └── services/           # External service integrations
β”œβ”€β”€ data/                   # Data layer
β”‚   β”œβ”€β”€ datasources/        # Remote and local data sources
β”‚   β”œβ”€β”€ models/             # Data models with JSON serialization
β”‚   └── repositories/       # Repository implementations
β”œβ”€β”€ domain/                 # Domain layer (business logic)
β”‚   β”œβ”€β”€ entities/           # Core business entities
β”‚   β”œβ”€β”€ repositories/       # Repository interfaces
β”‚   └── usecases/           # Business use cases
└── presentation/           # Presentation layer
    β”œβ”€β”€ blocs/              # State management (BLoC pattern)
    β”œβ”€β”€ screens/            # Full-screen views
    └── widgets/            # Reusable UI components

Key Technologies

  • State Management: BLoC Pattern with flutter_bloc
  • Dependency Injection: GetIt
  • Networking: Dio with custom interceptors
  • Local Storage: SharedPreferences + Hive
  • Animations: flutter_animate + Lottie
  • AI Integration: Google Generative AI (Gemini)
  • Subscriptions: RevenueCat
  • Authentication: Firebase Auth (optional)

πŸ§ͺ Testing

Run tests with:

flutter test

Run integration tests:

flutter drive --target=test_driver/app.dart

πŸ“± Building for Production

Android

flutter build apk --release
# or
flutter build appbundle --release

iOS

flutter build ios --release

πŸ”§ Configuration Options

Environment Variables

Variable Description Required Default
ENVIRONMENT App environment (development/staging/production) No development
GEMINI_API_KEY Google Gemini AI API key Yes* -
REVENUE_CAT_API_KEY RevenueCat public API key Yes* -
FIREBASE_API_KEY Firebase API key No -

*Required for full functionality. App will work with limited features without these keys.

Feature Flags

The app automatically enables/disables features based on available API keys:

  • AI Features: Enabled when GEMINI_API_KEY is provided
  • Subscriptions: Enabled when REVENUE_CAT_API_KEY is provided
  • Firebase Auth: Enabled when FIREBASE_API_KEY is provided
  • Mock Data: Enabled in development mode

🎨 Customization

Theming

The app uses Material Design 3 with custom colors. You can modify the theme in lib/main.dart:

ThemeData _buildTheme() {
  const primaryColor = Color(0xFFFF6B35); // Change this
  // ... rest of theme configuration
}

Adding New Features

  1. Create domain entities in lib/domain/entities/
  2. Define repository interfaces in lib/domain/repositories/
  3. Implement use cases in lib/domain/usecases/
  4. Create data models in lib/data/models/
  5. Implement repositories in lib/data/repositories/
  6. Add BLoC for state management in lib/presentation/blocs/
  7. Create UI screens and widgets in lib/presentation/

πŸ› Troubleshooting

Common Issues

  1. API Keys not working

    • Ensure keys are properly set in environment variables
    • Check that keys have proper permissions
    • Verify the keys are not expired
  2. Build failures

    • Run flutter clean && flutter pub get
    • Check Flutter and Dart SDK versions
    • Ensure all dependencies are compatible
  3. iOS build issues

    • Update CocoaPods: cd ios && pod install
    • Check iOS deployment target (minimum iOS 12.0)
  4. Android build issues

    • Check android/app/build.gradle for correct configurations
    • Ensure minimum SDK version is 21

Debug Mode

Enable debug logging by setting:

flutter run --dart-define=ENVIRONMENT=development

πŸ“„ License

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

🀝 Contributing

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

πŸ“ž Support

For support, email [email protected] or create an issue in this repository.

πŸ™ Acknowledgments


Made with ❀️ by the LetsCook team

About

cooking app! Gives you recipes! and step by step cooking instructions!

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors