vin_scanner 0.0.3 copy "vin_scanner: ^0.0.3" to clipboard
vin_scanner: ^0.0.3 copied to clipboard

'A customizable Flutter widget for live barcode scanning using Google ML Kit and the device camera. Supports front and back cameras with orientation lock, resolution presets, overlay styling, and conf [...]

example/lib/vin_scanner.dart

import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'package:vin_scanner/vin_scanner.dart';

/// The main entry point of the application.
void main() => runApp(const MyApp());

/// Root widget of the app.
class MyApp extends StatelessWidget {
  /// Creates the main app widget.
  const MyApp({super.key});

  /// Builds the MaterialApp widget and sets up the barcode scanner screen.
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      debugShowCheckedModeBanner: false,
      home: BarcodeScannerScreen(
        /// Callback invoked when a barcode is detected.
        onBarcodeDetected: (code, type) {
          debugPrint('Detected barcode: $code');
          debugPrint('Detected barcode type: $type');
        },

        /// Locks the device orientation to portrait mode.
        orientationLock: DeviceOrientation.portraitUp,
      ),
    );
  }
}
3
likes
0
points
44
downloads

Publisher

verified publisherflutterdevs.com

Weekly Downloads

'A customizable Flutter widget for live barcode scanning using Google ML Kit and the device camera. Supports front and back cameras with orientation lock, resolution presets, overlay styling, and configurable frame processing rate.'

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

camera, flutter, google_mlkit_barcode_scanning, permission_handler

More

Packages that depend on vin_scanner