# fluttertpc_flutter_barcode_scanner
**Repository Path**: openharmony-sig/fluttertpc_flutter_barcode_scanner
## Basic Information
- **Project Name**: fluttertpc_flutter_barcode_scanner
- **Description**: No description available
- **Primary Language**: Unknown
- **License**: MIT
- **Default Branch**: master
- **Homepage**: None
- **GVP Project**: No
## Statistics
- **Stars**: 0
- **Forks**: 7
- **Created**: 2024-11-11
- **Last Updated**: 2025-05-07
## Categories & Tags
**Categories**: Uncategorized
**Tags**: None
## README
# 🚨 **重要提示 | IMPORTANT**
>
> **⚠️ 此代码仓已归档。新地址请访问 [fluttertpc_flutter_barcode_scanner](https://gitcode.com/openharmony-sig/fluttertpc_flutter_barcode_scanner)。| ⚠️ This repository has been archived. For the new address, please visit [fluttertpc_flutter_barcode_scanner](https://gitcode.com/openharmony-sig/fluttertpc_flutter_barcode_scanner).**
>
---
>
# flutter_barcode_scanner
A plugin for Flutter apps that adds barcode scanning support on both Android and iOS.
[](https://pub.dartlang.org/packages/flutter_barcode_scanner)

## Try example
Just clone or download the repository, open the project in `Android Studio/ VS Code`, open `pubspec.yaml` and click on `Packages get`.
Connect device and hit `run`.
To run on iPhone you need to run from Xcode first time and just make `pod install` in `example/ios` then run from Xcode.
## Getting Started
Follow the steps for Android and iOS
PLEASE FOLLOW **iOS** STEPS CAREFULLY
### Android
:zap: Don't worry, you don't need to do anything.
### iOS - Requires Swift support
Deployment target : 12
#### 1. Fresh start:
1. Create a new flutter project. Please check for **Include swift support for iOS code**.
2. After creating new flutter project open `/ios` project in Xcode and set minimum **deployment target to 12**
and set **Swift version to 5**.
3. After setting up the deployment target and swift version, close the Xcode then run **pod install** in `/ios` in flutter project.
You have done with basic configuration now proceed to section **How to use**.
#### 2. Adding to existing flutter app:
#### If your existing ios code is **Swift** then you just need to do following.
1. Set **minimum deployment target to 12** and set **Swift version to 5**.
2. Close the Xcode and run **pod install** in `/ios` in flutter project.
3. Now proceed to section **How to use**.
#### If your existing ios code is **Objective-C** then you need to do following.
1. Create a new flutter project with same name at different location (Don't forget to check **Include swift support for iOS code** while creating)
2. Just copy newly created `/ios` folder from project and replace with existing `/ios`.
3. Open ios project in Xcode and set **minimum deployment target to 12** and set **Swift version to 5**.
4. Run **pod install** in `/ios`
**Note: If you did any changes in ios part before, you might need to make these configuration again**
## How to use ?
To use on iOS, you will need to add the camera usage description.
To do that open the Xcode and add camera usage description in `Info.plist`.
```