I am currently working with Angular 5 using Typescript. I need assistance in opening the file explorer window to add an attachment when clicking on an icon. I have successfully done this for a button, but I am facing issues with the click event binding on the icon. Can someone please provide some guidance?
<input type="file" #file (change)="upload()"/>
<span class="icon-doc" (click)="file.click()">
</span>
Here is the code snippet from my component :
upload(){
//This is where the code for uploading file(s) will go
}