Skip to content

Variable: cropByTag ​

ts
const cropByTag: ((tag, options) => CdnOperation) & NamedOperationCreator;

Defined in: ops/geometric.ts:160

Object-aware crop around detected faces or the main image content. Size is relative to the detected object (percent values).

See ​

https://uploadcare.com/docs/transformations/image/resize-crop/#operation-crop-by-objects

Example ​

ts
cropByTag('face', { ratio: '1:1' }) // → -/crop/face/1:1/