For example:
import {utils} from 'vue-file-agent';
// thumbnailSize: in pixels
// file instanceof File (optional)
// url - when file is not provided (optional). Returns promise
utils.resizeImage(thumbnailSize, file, url).then((data)=> {
console.log(data.image); // image instanceof Image - for further customization
console.log(data.canvas); // the canvas element
console.log(data.url); // the base64 string of resized image
console.log(data.color); // the average (or dominant) color calculated
});