Auto-Generated DOM
Compare auto-generated markup (empty div) vs. hand-written markup. Both produce identical uploaders.
Auto-generated (empty div)
Hand-written markup
Drag & drop files here
// Auto-generated: just an empty div
new MultipleUpload('#demo-auto', { uploadUrl: '/api/upload', multiple: true });
// Hand-written: full markup provided
new MultipleUpload('#demo-manual', { uploadUrl: '/api/upload', multiple: true });
Two ways to give the component a home
Point it at an empty <div> and it renders its own button, drop zone, preview area and queue. Give it markup that already carries the component's class names and it adopts what is there instead. Both produce the same working uploader; the difference is only who wrote the HTML.
Which to pick
Generated markup is the right default: less to maintain, and it keeps working when the component's internals change. Hand-written markup earns its place when the layout has to interleave with something else on the page — a button inside an existing toolbar, a queue rendered as rows of a table you already have.