Simple UIImagePickerController wrapper for SwiftUI
- Download the repo
- Drag and drop SUImagePickerView.swift file in your project bundle
- Presenting camera: SUImagePickerView(sourceType: .camera , image: self.$image, isPresented: self.$shouldPresentImagePicker)
- Presenting photo library: SUImagePickerView(sourceType: .photoLibrary , image: self.$image, isPresented: self.$shouldPresentImagePicker)
- Check ContentView.swift file for how to present the image picker
Thanks 👨🏻💻