ScreenshotableView

master

ScreenshotableView For SwiftUI
rushairer/ScreenshotableView

ScreenshotableView

Screenshotable view for SwiftUI

How to use?

@State private var sharedImage: UIImage?
@State private var shotting = false

...

// The view want to take screenshot
var content: some View {
...
}

ScreenshotableView(shotting: self.$shotting,
                   completed: { screenshot in
                   self.sharedImage = screenshot
                   self.shotting = false
}) {
    self.content
}

Description

  • Swift Tools 5.2.0
View More Packages from this Author

Dependencies

Last updated: Sun Oct 20 2024 16:28:55 GMT-0900 (Hawaii-Aleutian Daylight Time)