angular-material-components
angular-material-components copied to clipboard
File input form control is an empty object
<mat-form-field [appearance]="'outline'">
<ngx-mat-file-input
[multiple]="false"
[accept]="'image/*'"
[formControl]="this.fileFormControl"
><mat-icon ngxMatFileInputIcon>add_a_photo</mat-icon>
</ngx-mat-file-input>
</mat-form-field>
<pre>{{this.fileFormControl.value|json}}</pre>
This just shows an empty object after a file has been selected
How is it possible to access the binary of the file so I can post the data to an API endpoint?
Tried this component as well and couldn't figure it out. Seems like completely pointless component.