Screenshot

Improve this doc

$ ionic plugin add https://github.com/gitawego/cordova-screenshot.git

Repo: https://github.com/gitawego/cordova-screenshot.git

Captures a screen shot

Usage

import {Screenshot} from 'ionic-native';

// Take a screenshot and save to file
Screenshot.save('jpg', 80, 'myscreenshot.jpg').then(onSuccess, onError);

// Take a screenshot and get temporary file URI
Screenshot.URI(80).then(onSuccess, onError);

Static Members

save(format., quality., filename.)

Takes screenshot and saves the image

Param Type Details
format. string

Format can take the value of either 'jpg' or 'png' On ios, only 'jpg' format is supported

quality. number

Determines the quality of the screenshot. Default quality is set to 100.

filename. string

Name of the file as stored on the storage

Returns: Promise<any>

URI(quality.)

Takes screenshot and returns the image as an URI

Param Type Details
quality. number

Determines the quality of the screenshot. Default quality is set to 100.

Returns: Promise<any>

API

Native

General