Skip to content

🤖 AI-Assisted Coding Guidelines for Flutter ​

Core Principles ​

  1. AI output is never a substitute for developer understanding or proper review
  2. Every developer is responsible for fully understanding AI-assisted code
  3. Blindly pasting AI-generated code without review is prohibited
  4. AI tools enhance productivity but don't replace critical thinking

Approved Use Cases ​

  1. Widget scaffolding and UI component generation
  2. State management boilerplate (Cubit/Bloc setup)
  3. Model classes with JSON serialization
  4. Test case generation for widgets and business logic
  5. Documentation writing and code comments
  6. Theme and styling implementation

Common Violations ​

❌ DO NOT Violate These Rules ​

  1. Don't commit AI code without understanding it
  2. Don't use AI for security-critical implementations without review
  3. Don't paste sensitive data into AI tools
  4. Don't skip testing for AI-generated functionality

✅ ALWAYS Follow These Rules ​

  1. Review and understand all AI-generated code before use
  2. Test thoroughly any AI-assisted functionality
  3. Follow Flutter project standards and Dart coding conventions
  4. Get peer review for all AI-assisted code
  5. Validate security implications of AI suggestions
  6. Add proper error handling to AI-generated code