Skip to content

Event "vdropzone-error" does not seem to fire with AWS #506

Open
@g-traub

Description

@g-traub

Hi, I'm using v-dropzone in a project and for error handling I need to use "vdropzone-error" event, but it doesn't fire.
I tried replicating the problem : https://codesandbox.io/s/vdropzone-error-event-not-firing-lrx66?fontsize=14

  <div id="app">
    <img width="25%" src="./assets/logo.png">
    <Dropzone
      id="dropzone"
      :options="dropzoneOptions"
      :awss3="awss3"
      @vdropzone-s3-upload-error="error"
      @vdropzone-error="error"
    />
  </div>
</template>

<script>
import Dropzone from "vue2-dropzone";
import "vue2-dropzone/dist/vue2Dropzone.min.css";

export default {
  name: "App",
  components: {
    Dropzone
  },
  data() {
    return {
      dropzoneOptions: {
        paramName: "file",
        maxFilesize: 2
      },
      awss3: {
        // the bad url is what triggers the error
        signingURL: `url`,
        params: {},
        withCredentials: false,
        sendFileToServer: false
      }
    };
  },
  methods: {
    error() {
      console.log("error");
    }
  }
};
</script>

I get an error in the console :
Capture d’écran de 2019-11-06 16-07-18
But it doesn't fire the event

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions