I m trying to print a html file from my cordova app. I have installed the cordova-plugin-printer. In app.module.ts file imported the plugin and after that when i try to use this.printer.print('hello') Noting happens at all
import { Printer, PrintOptions } from '@ionic-native/printer/ngx';
private printer: Printer
Print(){
console.log("Print Pressed");
var options = {
font: {
size: 22,
italic: true,
align: 'center'
},
header: {
height: '6cm',
label: {
text: "\n\nDie Freuden",
font: {
bold: true,
size: 37,
align: 'center'
}
}
},
footer: {
height: '4cm',
label: {
text: 'Johann Wolfgang von Goethe, 1749-1832, deutscher Dichter, Naturforscher',
font: { align: 'center' }
}
}
};
this.printer.print("hello",options);
console.log("Print Pressed>>>");
}