Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

YanTao's avatar

how to upload file with vue.js

how to upload file with vue.js

0 likes
5 replies
rooser's avatar

I've been stuck for hours with that:

import FileUpload from 'vue-upload-component';

const app = new Vue({
  el: '#app',
  components: { FileUpload },
  data: {
    hello: 'Hello world!',
  }
});

I've got the error: Vue warn]: Unknown custom element: <file-upload> - did you register the component correctly? For recursive components, make sure to provide the "name" option. (found in root instance) I can't manage to figure out what's wrong, I've been changing it to CommonJS, it didn't make any difference...

YanTao's avatar

@atorscho now ,i am using vue2.x ,codecourse it has a course about file upload i think you can see that

Please or to participate in this conversation.