Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
const operation = async () => {
setImage(await PhotoManipulator.batch(IMAGE, operations(), { x: 40, y: 5, width: 600, height: 400 }, { width: 300, height: 200 }, 30))
setImagePng(await PhotoManipulator.batch(IMAGE, operations(), { x: 40, y: 5, width: 600, height: 400 }, { width: 300, height: 200 }, 30, MimeType.PNG))
};
const operation = async () => {
setImage(await PhotoManipulator.overlayImage(IMAGE, OVERLAY, { x: 30, y: 65 }))
setImagePng(await PhotoManipulator.overlayImage(IMAGE, OVERLAY, { x: 30, y: 65 }, MimeType.PNG))
};
const operation = async () => {
setImage(await PhotoManipulator.printText(IMAGE, texts()))
setImagePng(await PhotoManipulator.printText(IMAGE, texts(), MimeType.PNG))
};
const operation = async () => {
setImage(await PhotoManipulator.batch(IMAGE, operations(), { x: 40, y: 5, width: 600, height: 400 }, { width: 300, height: 200 }, 30))
setImagePng(await PhotoManipulator.batch(IMAGE, operations(), { x: 40, y: 5, width: 600, height: 400 }, { width: 300, height: 200 }, 30, MimeType.PNG))
};
const operation = async () => {
setImage(await PhotoManipulator.overlayImage(IMAGE, OVERLAY, { x: 30, y: 65 }))
setImagePng(await PhotoManipulator.overlayImage(IMAGE, OVERLAY, { x: 30, y: 65 }, MimeType.PNG))
};
const operation = async () => {
setImage(await PhotoManipulator.printText(IMAGE, texts()))
setImagePng(await PhotoManipulator.printText(IMAGE, texts(), MimeType.PNG))
};
const operation = async () => {
setCrop(await PhotoManipulator.crop(IMAGE, { x: 400, y: 200, width: 300, height: 200 }));
setResize(await PhotoManipulator.crop(IMAGE, { x: 400, y: 200, width: 300, height: 200 }, { width: 60, height: 40 }))
setCropPng(await PhotoManipulator.crop(IMAGE, { x: 400, y: 200, width: 300, height: 200 }));
};
const operation = async () => {
setImage(await PhotoManipulator.optimize(IMAGE, 5))
}