pdfmake icon indicating copy to clipboard operation
pdfmake copied to clipboard

Supported browsers

Open liborm85 opened this issue 9 years ago • 39 comments

Supported browsers

Add-ons used in browsers can affect the functionality of pdfmake. If pdfmake is not working try disable add-ons in browser.

Browser download() open() print() Issue(s)
Internet Explorer 9 no no no
Internet Explorer 10 only 0.1.x no no 3
Internet Explorer 11 only 0.1.x and 0.2.x no no 3
Edge 20 - 44 (engine: EdgeHTML) only 0.1.x and 0.2.x no no #693
Edge 79+ (engine: Blink) YES YES 1 YES 1
Edge (mobile) ??? ??? - #708
Firefox YES YES YES
Chrome YES YES 1 YES 1
Chrome (Android) YES YES 2 no?
Opera YES YES YES
Safari (iOS) YES YES / NO 4 YES / NO 4
Safari (iOS) iPhone YES YES -

(the list may not be complete)

1 ~works only without (or with disabled) AdBlock add-on (because in EasyList is blocked using blob, see commit https://github.com/easylist/easylist/commit/e3276b6ff9611e821d0e8ba7ac4dc336a4e3b765)~ Removed by commit easylist/easylist@e797d63. Methods works with AdBlock add-on now. 2 open invokes dialog to open document, see https://github.com/bpampuch/pdfmake/issues/679#issuecomment-464433414 3 playground preview is unsupported 4 require disabled popup blocker

liborm85 avatar Dec 29 '16 11:12 liborm85

Soooooo doesnt work on ie? Seriously?

nigel-dewar avatar Dec 29 '16 12:12 nigel-dewar

@nigel-dewar As says table - download on IE10+ works (tested on windows 10). IE9 doesn't work.

liborm85 avatar Dec 29 '16 12:12 liborm85

It might also be worth collecting the data URI lengths for the browsers. Because after this length only the download() option works (instead of open(), I haven't tried print()).

I know, in windows (7, 64-bit), the latest version of chrome supports 2MB and FireFox supports 1MB data URI's.

Chris--A avatar Dec 29 '16 13:12 Chris--A

After updating to the latest version .print() doesn't work anymore in chrome (chromium 57). It worked with the old version, not exactly sure about how old it was.

themasch avatar Mar 27 '17 12:03 themasch

Interest with Chrome:

  • open() and print() methods works only without or disabled AdBlock

(from issue: https://github.com/bpampuch/pdfmake/issues/954)

First post updated.

liborm85 avatar Apr 18 '17 12:04 liborm85

Which Version of Firefox is supported? I try to use it with an old (LTS) Version 16.0.2. Unfortunately I get the error: PdfMake is not defined... In the newest chrome everything works perfectly fast

I would use an older Version but it is always hard to find out which version supports which browsers... In a different life I would love to see a documentation by an autor which Version supports which Browser-Versions... But this is a general problem in the world of npm! Thanks for this great table, it is a beginning!

boom235 avatar Jun 15 '17 08:06 boom235

Is there any effort being made to resolve the incompatibilities with some of the browsers?

Holyphoenix avatar Jun 26 '17 17:06 Holyphoenix

FWIW, we are developing a new web application in .NET Core, Angular 4. There is a form that we have to output as PDF. I tested it yesterday on my iPhone 6s plus with a current version of iOS, and the PDF worked just fine. The PDF utilizes Columns, Tables, styling, so it isn't just trivial.

From that single test, I would conclude that under Safari, on iOS on iPhone, the open() function is supported although it shows a "no?" in the compatibility chart above.

TommyLCox avatar Jun 27 '17 13:06 TommyLCox

@TommyLCox Thanks for testing. Table updated.

liborm85 avatar Jun 28 '17 06:06 liborm85

Code https://jsfiddle.net/5ntw24qc/

On Phone Moto G4 / Android 7.0.0:

  • It's not working with Chrome 59.0.3071.125
  • Work with Firefox 54.0.1

On desktop it works in both browsers!

Update: Based on this i found a workaround, check it: https://jsfiddle.net/5ntw24qc/3/

uebbi avatar Jul 07 '17 17:07 uebbi

What about Opera?

i cheked. IE 11 - 11.0.9600 - not dowload, not opened Google chrome 60.0.31.... - opened, downloaded FF 54.0.1 - not dowload, not opened Opera 47.0 - opened, downloaded

oscarhandsome avatar Aug 15 '17 09:08 oscarhandsome

Could you please add this on the bottom of the pdfmake welcome page?

FlorianLeitgeb avatar Nov 27 '17 09:11 FlorianLeitgeb

Chrome on Android throws error after download pdf file - "download failed due to unknown error":

  • Chrome on Android 6.x, works without error
  • Chrome on Andorid 7.x, throw error, fixed in Chrome version 60+ (actual version is 63)

(source: https://github.com/eligrey/FileSaver.js/issues/330)

=> In actual Chrome versions works download() correctly in Android 6 and 7.

liborm85 avatar Dec 25 '17 15:12 liborm85

Problem with AdBlock in Chrome is caused in EasyList by commit https://github.com/easylist/easylist/commit/e3276b6ff9611e821d0e8ba7ac4dc336a4e3b765. The blob rule is quite strict. I don't know how this rule can get away from list.

liborm85 avatar Dec 25 '17 16:12 liborm85

hi, first of all i appreciate you guys u did a great job .

i am using pdfmake for my html need to export as PDF for 1 page means for small data it is working fine.

but for large data the pdf pages will split into two and they dont return any content . its just returns empty pdf pages

Can you please help me to sort out this @liborm85.

my code: vm.exportPDF = function () { html2canvas(document.getElementById('exportthis'), { onrendered: function (canvas) {
var data = canvas.toDataURL(); var docDefinition = { content: [{ image: data, width:500, }], pageBreakBefore: function (currentNode, followingNodesOnPage, nodesOnNextPage, previousNodesOnPage) { return currentNode.headlineLevel === 1 && followingNodesOnPage.length === 0; } }; pdfMake.createPdf(docDefinition).download("BCQAM-Summary-report.pdf"); } }); }

Ananyag avatar Jul 13 '18 14:07 Ananyag

Please update the table. Pdfmake doesn't work for me, at least on open() method in Firefox 62.0 with uBlock Origin enabled. It works if I disable uBlock Origin.

me21 avatar Sep 20 '18 11:09 me21

disable ublock and try again

On Thu, 20 Sep 2018 at 13:41, Alexandr Zarubkin [email protected] wrote:

Please update the table. Pdfmake doesn't work for me, at least on open() method in Firefox 62.0 with uBlock Origin enabled.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/bpampuch/pdfmake/issues/800#issuecomment-423151954, or mute the thread https://github.com/notifications/unsubscribe-auth/AKQm5w7SmVFiykyz-7NNXBXwetTohkQBks5uc37UgaJpZM4LXiOR .

Wabbala avatar Sep 20 '18 14:09 Wabbala

Is not possible test pdfmake with all various add-ons in browsers. Notice added to first post.

Firefox 62 with add-on AdBlock works ok.

liborm85 avatar Sep 23 '18 12:09 liborm85

Works in Safari 12 (13606.2.11) for macOS, even with AdBlock installed

markusand avatar Oct 04 '18 15:10 markusand

I was able to do a short test:

Edge (mobile): Edge 38, EdgeHTML 41, WP10 1607 Tested open, download, print Nothing works.

Rotzbua avatar Nov 09 '18 17:11 Rotzbua

Supported browsers rewrited to new documentation - https://pdfmake.github.io/docs/getting-started/client-side/supported-browsers/

liborm85 avatar Dec 25 '18 14:12 liborm85

open() of Safari's mac can't push download button in the PDF viewer..

moffsugita avatar Feb 07 '19 08:02 moffsugita

@moffsugita How it related to pdfmake? PDF is opened in viewer, and download button depends to this viewer. Problem is in pdf viewer not in pdfmake.

liborm85 avatar Feb 08 '19 14:02 liborm85

CreatePDF doesn't work with Brave web browser (just downloads PDF), even though it's built on top of Chromium (just a more secure version of Chrome). This is inconvenient since there is no way my app can tell the difference.

dethier1958 avatar Mar 20 '19 17:03 dethier1958

I tried to solve method open and print in Chrome with AdBlock and it looks good.

How does it work: If the window is closed immediately after opening (eg. by adblock) pdfmake use actual window to open pdf.

Try to test this pdfmake: pdfmake-adblock-fix.zip

Please test it and send feedback. Thanks.

liborm85 avatar May 05 '19 14:05 liborm85

Hi everyone I know I am very late to this thread. I have been thinking about everyone wanted to see the open and print methods working in all browser. We have to consider that not every browser have render capabilities when reading a pdf. For me and even for the users, downloading the pdf should be enough for all cases. We can't depend whether a browser can read pdf or not. I know having the pdf reader in the browser or embed in iframe looks cool and awesome. I think our biggest bet to overcome all this incompatibilities issues may be using this https://github.com/mozilla/pdf.js/. I have never try it before but seems compatible with most html5 compliance browsers https://github.com/mozilla/pdf.js/wiki/Frequently-Asked-Questions#faq-support. I know this is out of scope of pdfmake but this would be a great integration for the people with need of viewing and printing the pdf in browser. Cheers!

arivera12 avatar Oct 09 '19 23:10 arivera12

@arivera12 Not related with pdfmake.

liborm85 avatar Oct 12 '19 10:10 liborm85

@arivera12 Not related with pdfmake.

Of course it doesn't, but may help others achieve what is not supported yet.

arivera12 avatar Oct 12 '19 19:10 arivera12

I am trying on mobile. Work fine with browser but doesn't work on a webview in mobile app (Android and ios)

cristiandaulisio avatar Jun 30 '20 16:06 cristiandaulisio

I am trying on mobile. Work fine with browser but doesn't work on a webview in mobile app (Android and ios)

Same here. Did you find a solution ?

mignam avatar Jan 11 '21 10:01 mignam