How to print data into printer

Anyone can help me or give some link or tutorial on how to print data to printer in ionic 3?

print(): void {
    } else {
        console.warn("window is not defined");

Ionic-native plugin?

i dont want to print the whole window, i just only want to print the data with specific format and headers like a formal document.

actually i already use printer plugin in ionic native, but i do not know how to run it or use it because i don’t see any full tutorial on how to use ionic printer plugin in ionic, they only show how to set up.

you have to call the function

this.printer.print('put your content here', options).then(onSuccess, onError);

check the page on GitHub

hi yajuve, i already try that repo of katzer/cordova-plugin-printer but when i try to intall it theirs an error. npm error.

Hi @deloadrian1969, did you find any good solution to your problem as I am facing the same problem. I also want to print the specific content, also in my app, I want to use all type of printers say bluetooth, net printer and even USB. So, please help me if you have done something like this or if you know any good package which can do this work?
Thanks :slight_smile: