Technology : Angular4
In Firefox, When I upload images by Froala editor then its throwing some error in console. I am using Angular4
But In chrome its working fine.
I am using below mention version in my Angular4 application
Froala version : angular-froala-wysiwyg": "^2.8.4"
Error in console are :
ReferenceError: event is not defined[Learn More]
File :
export class BlobUploader{
public static options: Object = {
charCounterCount: true,
fileUpload: false,
videoUpload: false,
events : {
'froalaEditor.image.beforeUpload': function (e, editor, files) {
alert(files);
if (files.length) {
var image=(<HTMLInputElement>event.target).files[0];
if(image.size<65000){
var reader = new FileReader();
reader.onload = function (e) {
var result = reader.result
editor.image.insert(result, null, null, editor.image.get());
};
reader.readAsDataURL(files[0]);
}
else{
alert('Image Size Exceeded threshold value <br> Please upload an image of smaller size!')
}
}
return false;
},
}
Technology : Angular4 In Firefox, When I upload images by Froala editor then its throwing some error in console. I am using Angular4 But In chrome its working fine.
I am using below mention version in my Angular4 application Froala version : angular-froala-wysiwyg": "^2.8.4"
Error in console are : ReferenceError: event is not defined[Learn More] File : export class BlobUploader{ public static options: Object = { charCounterCount: true, fileUpload: false, videoUpload: false, events : { 'froalaEditor.image.beforeUpload': function (e, editor, files) { alert(files);
}; } Please team help me how to fixed that issue.