Skip to content

l-ll/alloy-crop-vue

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AlloyCrop-vue

AlloyCrop vue wrap demo

AlloyTeam/AlloyCrop

params

Param Description
confirmText confirmText
cancelText cancelText
output output
width width
height height
circle circle
imgPath imgPath
res.data crop canvas

💡️ try exif-js get orientation

example

js

import AlloyCropVue from 'alloycrop-vue'
Vue.use(AlloyCropVue)
this.$crop({
  imgPath: URL.createObjectURL(file)
}).then(res => {
  if (res.type === 'confirm') {
    // base64 res.data.toDataURL('image/png')
    // blob res.data.toBlob(blob => {}, `image/png`)
  }
})