JSFiddle - React, Tailwind, and code Playground
HTML
<script src="https://cdnjs.cloudflare.com/ajax/libs/dropzone/4.3.0/dropzone.js"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/dropzone/4.3.0/dropzone.css">
<script src="https://code.jquery.com/jquery-2.2.4.min.js"></script>
<button id="but">
Process Queue
</button>
<div id="image-uploader" style="height:500px;width:500px;background-color:#fff;border:3px solid red;">
</div>
JavaScript
$(function (){
var el = document.getElementById("image-uploader");
var config = {
url: '/foo',
autoProcessQueue: false,
uploadMultiple: true,
parallelUploads: 15,
maxFiles: 15,
acceptedFiles: "image/*",
init: function () {
this.on("queuecomplete", function () {
alert("I Think I should only see this once.");
});
}
};
var dropZone = new Dropzone(el, config);
$('#but').click(function(){dropZone.processQueue();})
});