Best (preferably offline) HTML viewer? Minimal resources?
from A_norny_mousse@feddit.org to linux@lemmy.ml on 08 Apr 07:45
https://feddit.org/post/10441216

I have wondered many times.

Of course I can always use a browser but it’s overkill.

The same goes for yad or zenity, they pull in webkit which is a full-fledged browser engine, and at least yad does not have an offline mode.

I just want to look at some local HTML (incl. images) & CSS styling.

#linux

threaded - newest

tom@jlai.lu on 08 Apr 07:52 next collapse

Dillo?

domi@lemmy.secnd.me on 08 Apr 08:51 next collapse

Maybe an e-book reader like KOReader? flathub.org/apps/rocks.koreader.KOReader

Plenty of them support local HTML.

juliebean@lemm.ee on 08 Apr 14:19 collapse

probably most of them do. epubs are mostly html after all.

JubilantJaguar@lemmy.world on 08 Apr 11:12 next collapse

weasyprint will convert it to PDF. I use it in a script to make my emails readable offline.

racketlauncher831@lemmy.ml on 08 Apr 11:15 next collapse

Do you just want to see the text content of a HTML file? - a text editor

Do you want most, if not all, HTML tags to be rendered as pretty graphical shapes?

Do you want the text have proper fonts?

Styles? You need something to parse CSS files.

What about dynamically generated content like ten smiley faces? You need a JavaScript engine.

Do you also want to see iframes? You need it to be capable of sending XHR requests.

What if it references to a piece of WebAssembly?

It’s way more complicated than you anticipated.

BaumGeist@lemmy.ml on 08 Apr 11:19 next collapse

litehtml looks promising, but I can’t vouch for it

atzanteol@sh.itjust.works on 08 Apr 12:37 next collapse

Of course I can always use a browser but it’s overkill.

No, it’s exactly what you want.

Drito@sh.itjust.works on 08 Apr 13:26 next collapse

You can also use a light browser such as Qutebrowser.

MonkderVierte@lemmy.ml on 08 Apr 14:17 next collapse

Dillo? Or terminal? Then lynx or links2.

D_Air1@lemmy.ml on 08 Apr 17:54 next collapse

Believe it or not. kde’s khelpcenter is what I have been using. Not sure if it includes images, but it renders simple html files and according to the Arch package. It is only like 7 MiB. Way better and faster than using a whole browser, but doesn’t really support javascript obviously.

A_norny_mousse@feddit.org on 08 Apr 18:42 collapse

Thanks! Unfortunately my system is not KDE so it would pull in too much.

yelp (help for gnome) can render HTML, too.

I’ve been trying different things; in the end I guess something like yad or zenity is still the best. netsurf is really fast but I don’t know how to style it as a viewer without a toolbar/urlbar.

I’d love to find a simple frontend to litehtml.

cerement@slrpnk.net on 08 Apr 18:50 next collapse

Offpunk

(technically a console browser – Debian installed size 352 KB)

zyberlex@lemmygrad.ml on 10 Apr 02:12 next collapse

FWIW “just displaying html” is one of those can of worms type problems that looks easy enough to start making but actually impossible to do fully correct.

You want something thats doing a WebView, so if not a Firefox then maybe one of the lighter weight ones like Falkon or Gnome Web etc.

inawhilecrocodile@lemmy.ml on 10 Apr 03:03 next collapse

Netsurf uses GTK, it’s own html 5, css 2 engine and the install size is 6mb not including gtk.

packages.debian.org/bookworm/netsurf-gtk

www.netsurf-browser.org

Psythik@lemm.ee on 10 Apr 04:05 next collapse

Notepad++ in WINE

cy_narrator@discuss.tchncs.de on 14 Apr 05:33 collapse

A more lightweight browser?

You gotta understand, browsers are designed to be HTML parsers. You can write an HTML file and double click to open in browser so your only option is a web browser.

Some browsers are certainly light weght than others, find the one that suits your need and use it