dpr method
- int dpr
To implement the device pixel ratio functionality of the Image Delivery API, you require two parameters "dpr" and "height or width". For more details read the documentation: https://www.contentstack.com/docs/developers/apis/image-delivery-api/#set-device-pixel-ratio
For more details, Read documentation: https://www.contentstack.com/docs/developers/apis/image-delivery-api/#dpr
Example
final stack = contentstack.Stack(apiKey, deliveryToken, environment);
final imageTransformation = stack.imageTransform(imageUrl);
final response = await imageTransformation.dpr(30, 60, 12).fetch();
Implementation
void dpr(int dpr) {
query.append('dpr', dpr.toString());
}