Photo upload component, not trying to be "reusable component". It works on its own or you can use it as a starting point.
Example
Vue.component('photo-upload', require('./components/PhotoUpload.vue'));
and
<photo-upload @input="handleFileUpload" :value="value"></photo-upload>
Optional parameter disabled
to enable/disable compnent.
Value is current image preview (if image is already uploaded)
Example how to upload photo, or other way is to serialize file with base64.
handleFileUpload(file){
let form = new FormData();
form.append('photo', file);
// or this.$http
axios.post(`/api/upload`, form).then(res => {
}, res => {
});
},