Hacker News new | ask | show | jobs
by ldjb 3275 days ago
Plain HTML isn't so good if you want to include images in your document or have multiple pages. You end up making the user download a whole bunch of files if they want a copy of the document.

The great thing about EPUB is that all the files are bundled together in a single .epub file. You can copy the file and move it around without worrying about keeping the structure intact.

I think that perhaps the main issue currently present with EPUB is that EPUB readers aren't really part of the standard installation on devices. Pretty much every PC or smartphone you come across in the wild will have software installed to view PDFs, but the same isn't the case for EPUB. I think Apple have done a good thing by including an EPUB reader (iBooks) as part of macOS and iOS, but that's not the case for other operating systems.

It might be nice if web browsers could natively act as EPUB viewers, in the same way a number of them natively act as PDF viewers. That way, the user already has an EPUB viewer installed, and they don't have to go and find and install one.

2 comments

Now that I think about it I'm kind of surprised that browser don't natively show EPUB files.
there are plugins for that (same as you have with PDFs, though you reuse same rwndering engine, since EPUBs are html documents under the hood)
There are plugins, but having to find and install one is an extra step that I think a lot of people don't take.

It's far different than being able to link to a PDF file and having it instantly display in the browser. As far as I'm aware, Firefox, Chrome and Safari (and possibly other browsers) can all display PDFs natively, so I think it would be convenient if they could also display EPUBs without the need for additional plugins.

As you say, EPUBs use HTML under the bonnet, so rendering should be pretty straightforward.

I hope one day all popular browsers will render EPUB straight away. Should be lot easier then PDF.
> Plain HTML isn't so good if you want to include images in your document or have multiple pages.

Am I missing something? This is practically the only thing that vanilla HTML is good at?

It seems like you could get all the benefits of EPUB with an archive of HTML files.

EPUB is an archive of HTML files.

It has a handful of metadata files to tie all those HTML files together, but it is essentially a ZIP container full of HTML, CSS, JS, and images. Rename filename.epub to filename.zip and open it up some time.