refactor: Update lint rule

This commit is contained in:
Koji Wakamiya 2025-12-29 08:49:23 +09:00
parent b63e14b46d
commit d667dffad7
No known key found for this signature in database
3 changed files with 20 additions and 5 deletions

View File

@ -1,4 +1,17 @@
include: package:flutter_lints/flutter.yaml
# Additional information about this file can be found at
# https://dart.dev/guides/language/analysis-options
analyzer:
language:
strict-raw-types: true
exclude:
- '**.g.dart'
linter:
rules:
avoid_equals_and_hash_code_on_mutable_classes: true
type_annotate_public_apis: true
comment_references: true
prefer_const_constructors: true
prefer_const_constructors_in_immutables: true
prefer_const_declarations: true
prefer_const_literals_to_create_immutables: true

View File

@ -5,6 +5,7 @@ import 'dart:async';
import 'package:flutter/foundation.dart';
import 'package:platform_image_converter/src/android/shared.dart';
import 'package:platform_image_converter/src/darwin/shared.dart';
import 'package:platform_image_converter/src/image_conversion_exception.dart';
import 'package:platform_image_converter/src/image_converter_platform_interface.dart';
import 'package:platform_image_converter/src/output_format.dart';
import 'package:platform_image_converter/src/output_resize.dart';

View File

@ -1,6 +1,7 @@
import 'dart:async';
import 'dart:typed_data';
import 'package:platform_image_converter/src/image_conversion_exception.dart';
import 'package:platform_image_converter/src/output_format.dart';
import 'package:platform_image_converter/src/output_resize.dart';
@ -10,9 +11,9 @@ import 'package:platform_image_converter/src/output_resize.dart';
/// Handles the core logic of image format conversion on each platform.
///
/// **Implementations:**
/// - [ImageConverterDarwin]: iOS and macOS using ImageIO
/// - [ImageConverterAndroid]: Android using BitmapFactory
/// - [ImageConverterWeb]: Web using Canvas API
/// - ImageConverterDarwin: iOS and macOS using ImageIO
/// - ImageConverterAndroid: Android using BitmapFactory
/// - ImageConverterWeb: Web using Canvas API
abstract interface class ImageConverterPlatform {
/// Converts an image to a target format.
///