Repository navigation
NativeBoat 0.1.0-alpha.5
Pre-release
Pre-release
·
227 commits
to main
since this release
- NativeBoat is open source under the MIT license. Its source, releases and
documentation are in the nativeboat
repository, and built applications'THIRD-PARTY-NOTICES.txtincludes
NativeBoat's own MIT notice. - HTTPS responses stream as they arrive:
dataevents follow the
download, a response read slowly pauses it, and large downloads such as
updates no longer wait whole in memory.rejectUnauthorized: false, on
the request or its agent, andNODE_TLS_REJECT_UNAUTHORIZED=0accept
server certificates Windows does not trust, as in Node. - Form controls check their constraints as Chromium does:
required
(radio groups and select placeholders included),pattern, email
addresses and URLs, number and date ranges and number steps, with
Chromium's messages invalidationMessage.:validand:invalid
match controls, forms and fieldsets, andsetCustomValiditymakes a
control invalid. -webkit-text-fill-colorfills text,font-kerning: nonekeeps glyph
pairs unkerned, and-webkit-user-dragdecides whether pressing and
moving over an element drags it:nonekeeps images and links still and
elementdrags any element.- Drawn selects place their arrow where Chromium does, 8.5 pixels inside
the right border whatever the padding, and checkboxes and radio buttons
made fully transparent, as switches lay them over their track, show the
page beneath them and still take the clicks. ::beforeand::afterboxes in the flow paint their backgrounds and
borders, so an empty dot drawn withcontent: ""shows.- Text fields with transparent text show what the page draws beneath
them, with their caret and placeholder, as fields laid over a
highlighted copy of their text expect; translucent field text blends as
CSS colors do. text-underline-offsetplaces underlines that far below the baseline.- In preloads,
process.nextTickcallbacks the page's code queues run
after the page has rendered, as on Electron's next Node turn, so work a
library starts that way no longer holds back the page's next frame. - Main processes and preloads have Node's global
performance:now(),
timeOrigin, marks and measures with their entries, andtoJSON(). nativeboat build --config <FILE>reads a settings file for the native
build, so the project needs no change: itspublishnames the feed native
builds update from, before package.json'snativeboat.publish.- Checkboxes and radio buttons look as in Chromium, and fill with the
page'saccent-colorwhen checked. - The pointer over a form control moves over the page:
:hoverstyles,
mousemove,mouseoverandmouseenterevents and the hover look of
checkboxes follow it, and controls show the cursor their style asks
for, such ascursor: pointer. child_process.spawnSyncworks as in Node: it returns the process's
pid,status,stdout,stderrandoutput, asBuffers or in the
encodingasked for, and a program that cannot start gives anerror
with Node'scode, such asENOENT.- A label the pointer is over or presses hovers or presses its control
too, as in Chromium::hoverand:activestyles and the hover look of
a checkbox follow the pointer over its label. nativeboat analyzereports React as Partial anddisplay: contentsas
Supported, as the compatibility list does, and its notes for web fonts
and web notifications say what works.- Applications that keep only some Electron locales with
electron-builder'selectronLanguagestake their locale from those, as
Electron does from the resources it ships: an application keeping only
en-USreportsen-USfromapp.getLocale()andnavigator.language
on a Chinese Windows, and uses English default fonts.monospaceis
Courier New before Electron 36, which made it Consolas where text uses
ClearType. - Single-line text fields stay in the middle of their line when the page
around them scrolls or changes size; their text and placeholder used to
jump to the top of the line. - Buttons laid out as blocks or flex containers in the flow of text are
as wide as their content when their width isauto, as in Chromium,
rather than as wide as their container. - Styled selects are as tall as in Chromium: their label's line is the
height of the primary font's, whatever fonts the label falls back to,
with a device pixel above and below it unlessappearance: none. app.getPreferredSystemLanguages()lists the languages of Windows'
language settings, such aszh-Hans-CN, and pages'navigator.languages
is the application's locale followed by them, as in Electron.nativeboat buildprints the project's warnings, such as electron-builder
settings it does not use. Applications that open no windows, such as tray
applications, are not warned that no page was found.- Message boxes look and answer as Electron's: a message without a
detailis the dialog's content, buttons named OK, Cancel, Yes, No,
Retry or Close are the dialog's own and other buttons are command links
unlessnoLinkis set, an empty title shows the application's name,
defaultIdandcancelIdtake Electron's defaults, and
checkboxLabeladds a checkbox whose state the result reports.
dialog.showOpenDialogSync,showSaveDialogSyncand
showMessageBoxSyncare available, and a canceled save dialog gives an
emptyfilePath. safeStorageencrypts and decrypts as Electron does on Windows: its key
is protected for the user by Windows and kept inLocal Statein the
user data directory, so text an Electron build of the application
encrypted decrypts in the native build.powerSaveBlockerkeeps the
computer, or also the display, from sleeping.powerMonitorreports idle time and state, whether the computer runs on
its battery, and emitssuspend,resume,on-ac,on-battery,
lock-screenandunlock-screen.systemPreferencesgives the accent
color, Windows' system colors, animation settings and media access, and
emitsaccent-color-changedandcolor-changed, as in Electron.- The
webContentsmodule finds the contents of the application's
windows:getAllWebContents,fromIdandgetFocusedWebContents. - Windows take the
iconoption andsetIcon, and windows without one
show the application's icon.autoHideMenuBarhides the menu bar until
Alt shows it, withsetMenuBarVisibility,setAutoHideMenuBar,
isMenuBarVisibleandisMenuBarAutoHide. Thetransparent,
alwaysOnTopandskipTaskbaroptions work, and Electron's macOS-only
window methods, such assetSimpleFullScreenandisDocumentEdited,
exist and behave as Electron's do on Windows. - Menus look like Electron's: rounded corners, Chromium's shadow, and
shortcuts and submenu arrows sharing the right column. - Rounded corners, elliptical ones included, are antialiased as in
Chromium, for backgrounds, borders and clipped content. Thin strokes,
such as those of icons, keep their weight. - SVG files work as images again, in
<img>and as backgrounds, drawn as
vectors at any size. - Videos show their poster or first frame and report their duration and
loading events, with Chromium's colors and scaling. nativeImagebehaves as Electron's on Windows: JPEG and icon files,
thumbnails at the size asked for,resizeandcropas Chromium does
them,toJPEG, scale factors and representations, and Electron's
errors.- Shadow DOM:
attachShadow, slots, and styles, layout and painting of
shadow trees, with:hostand::slotted(). Custom elements:
customElements.define, upgrades and the lifecycle callbacks.
:lang(),:dir()and:nth-child(An+B of S)match, and@supports
accepts declarations whose values usevar(). - Pages can start dedicated workers. They run on the page's thread, each
with a worker global of its own, and exchange messages and errors with
the page. A worker can be made from a function's text, since
Function.prototype.toStringreturns the source of functions a program
reads as text. - Message ports:
MessageChannel,MessagePortandBroadcastChannel
in Node code and inworker_threads. Electron'sMessageChannelMain
ports pass between the main process, preloads and pages through
webContents.postMessage, andutilityProcessand
child_process.forkrun modules as child processes with message
channels. - Node's
cryptomodule runs on Windows' cryptography (CNG): MD5, SHA-1
and SHA-2 hashes, HMACs, PBKDF2 and HKDF, AES in ECB, CBC, CTR and GCM
modes, random values,timingSafeEqual, secret keys and X.509
certificates. Every page and process has the Web Crypto API:
getRandomValues, andcrypto.subtlewith SHA digests, HMAC, AES-GCM,
AES-CBC, AES-CTR, PBKDF2 and HKDF; other algorithms reject with
NotSupportedError. - Main processes and preloads have Node's
WebSocketclient forws:
andwss:URLs, through the system's TLS and proxy settings. @vscode/sqlite3databases run on Windows' own SQLite (3.38 or later)
when the system has it, and otherwise on a built-in engine that covers
tables, indexes, constraints, queries, upserts, transactions, pragmas and
ALTER TABLE ... ADD COLUMNandRENAME TO.- WebAssembly modules load and run, with the JavaScript API over them.
They are interpreted, so they run slower than in Electron. - More of Node:
netservers and clients over Windows named pipes,
vmcontexts (without evaluating code strings),inspector(with no
debugger attached),moduleresolve hooks andcreateRequire,
diagnostics_channel,perf_hooks,v8,dns,util/types,
process.memoryUsage,cpuUsage,uptime,availableMemory,
releaseandconfig, and anavigatorglobal outside pages. A child
process's output streams giveBuffers untilsetEncodingis called. - More of Electron: the
protocolmodule'shandle,
registerFileProtocol,registerBufferProtocoland
registerStringProtocolserve style sheets, images, fonts, media and
fetchto pages.apphasenableSandbox, the logs path,focus,
metrics, GPU status, jump list settings, accessibility support, proxies
and protocol clients, and every window shares one default session.
WebContentsViewbuilds with a warning and throws if used. nativeboat analyzereports Windows named pipes innet, the system
SQLite behind@vscode/sqlite3, and top-levelawaitas Partial.- Native addons the runtime provides in place of their binaries:
@vscode/windows-registry,@vscode/deviceid,@vscode/windows-mutex,
@vscode/policy-watcher,@vscode/windows-process-tree,
@vscode/windows-ca-certs,@vscode/os-proxy-resolver,
@vscode/spdlog,@vscode/sqlite3,@vscode/native-watchdog,
@parcel/watcher,node-ptyandnative-is-elevated. - JavaScript and TypeScript: top-level
await(a dynamicimport()waits
for the module, a static import does not),usingandawait using
declarations, TypeScript classes withexperimentalDecorators, enums
and namespaces astsccompiles them,import x = require(), and
import()of a specifier computed when the program runs, among the
modules the build can find. Arequirethe build cannot satisfy warns
at build time and throwsMODULE_NOT_FOUNDwhen it runs, as in Node. - Projects: plugin packages, named by folder globs in the
plugins
setting of a settings file or package.json'snativeboatkey, are
found, get their dependencies installed and compile with the
application. Projects that download Electron themselves are recognized,
and gulp or grunt tasks that produce files the project's stylesheets
name run before compiling. An application's modules and installed
packages run from the executable's folder, as a packaged application's
do, with the files its production dependencies read at run time beside
them. - Large applications build: very large modules and long chains of
operators compile, and long toolchain command lines no longer fail. The
build cache takes about half the disk it did, and rebuilding one part
of an application no longer recompiles the parts that depend on it.
NATIVEBOAT_KEEP_GOINGreports every part that fails to compile instead
of stopping at the first. fs.watchand@parcel/watcherreport changes made right after a watch
starts; on a busy computer the first changes could go unreported. A
forked child that sends a message and then disconnects, as in
process.send(message, () => process.disconnect()), delivers the
message before its parent seesdisconnect.nativeboat analyzejudges a window'swebContentsand the default
session member by member, reportsnavigator.clipboard.readTextand
writeTextas supported and the rest of the Clipboard API as partial,
leaves Vue's:deep(),:slotted()and:global()to Vue, and parses
TypeScript as TypeScript.
Download nativeboat-0.1.0-alpha.5-windows-x64.zip, extract it and add the folder to your PATH; see the README. SHA256SUMS.txt holds the archive's checksum.