zefoy / ngx-dropzone-wrapper

Angular wrapper library for Dropzone
MIT License
174 stars 51 forks source link

How to use dropzone() #102

Closed ft115637850 closed 6 years ago

ft115637850 commented 6 years ago

I use below code to try to get instance of dropzone, but failed. <div #dropzoneRef class="dropzone" [dropzone]="dropzoneConfig" (error)="onUploadError($event)" ></div> @ViewChild('dropzoneRef', {read: ElementRef}) dropzoneRef: ElementRef; const dz = this.dropzoneRef.nativeElement.dropzone();

The error is 'UploadModelComponent.html:102 ERROR TypeError: this.dropzoneRef.nativeElement.dropzone is not a function'.

Did I missed anything?

ft115637850 commented 6 years ago

I got this from your StackBlitz example. Nice wrapper! Thanks!