> After wrestling with [the constraints of] this for several years, we imagined an environment that was not designed for traditional scrolling web content, but was intended to be a runtime environment for rich client applications built with the same technologies -- HTML, CSS, JavaScript -- and designed from the ground-up to run on constrained, embedded, Living Room Consumer Electronics (CE) devices...
> The Cobalt Authors forked H5VCC, removed most of the Chromium code -- in particular WebCore and the Chrome Renderer and Compositor -- and built up from scratch an implementation of a simplified subset of HTML, the CSS Box Model for layout, and the Web APIs that were really needed to build a full-screen SPA browse and play application.
Even this is too much I think.
Sciter is 7 Mb on Windows and 11 Mb on RaspberryPi. Extra 3 Mb is Skia for rendering on Vulkan and/or OpenGL. And it supports full set of HTML5 elements. JavaScript is at full ES2020 level.
The only reason I think why 45 Mb is there is because of video codecs. Sciter does not have them in core. But as loadable ffmpeg based plugin.
Can Cobalt run, say, ChartJS as it is (https://sciter.com/chartjs-in-sciter/)? Seems like not as I do not see <canvas> in the list of its supported elements.
Features which the project actually needs will be decisive.
Does the project need Canvas? Sciter is the better choice.
Does the project need CSS Flexbox? Cobalt will be a better fit.
The binary size may play a role if all else is equal ...
Sciter's flex units + CSS flow property is a superset of flexbox and grid features. For example paddings, margins, border widths, left|right|top|bottom can be expressed in flex units.
Everything that can be defined by flexbox can be expressed by flex units / flow:
https://terrainformatica.com/w3/flex-layout/flex-vs-flexbox....
That's a critical distinction when you want to run the same codebase as you have on the web.
/* browser */
@supports (display:flex)
{
section { display: flex; }
section > * { flex: 1; margin:1em; }
...
}
/* sciter */
@supports (flow:horizontal)
{
section { flow:horizontal; }
section > * { width:1*; margin:1em; }
...
}
You should not assume that all browsers support same set of features. And needless to say, that Sciter is not a universal browser. And so is Cobalt in that respect - it is a browser for particular site / application.Yes, a return to the dark days of UAs having their own proprietary extensions / prefixes to do the same thing. Why bother when there's an actual industry standard?
> You should not assume that all browsers support same set of features.
You can certainly target only user agents which support CSS Flexbox. I would even say it's the advisable default unless you have some very special needs.
It supports rendering trough Direct2D/DirectX, GDI+, CoreGraphics, Cairo and (through Skia) DX12, Vulkan, Metal.
Disclosure: I work at Ekioh.
https://cobalt.dev/development/reference/supported-features....
but the result is more appropriate for some kinds of embedded environments.