npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@domicile-desktop/system-network

v0.0.0-alpha-bfbc2e9a3043

Published

The network for a Domicile shell, from NetworkManager, iwd or wpa_supplicant: connectivity and the primary connection, with its Wi-Fi network and signal, kept current.

Readme

@domicile-desktop/system-network

The network for a Domicile shell, from NetworkManager, iwd or wpa_supplicant: connectivity and the primary connection, with the Wi-Fi network's name and signal. The Wi-Fi device, from NetworkManager or iwd: its networks and connection, and the requests that change them. Built on @domicile-desktop/sdk/system.

Usage

import { system } from "@domicile-desktop/sdk/system";
import { watchNetwork } from "@domicile-desktop/system-network/network";

const stop = watchNetwork(system(domicile), (network) => {
  network.match({
    Err: () => hide(),
    Ok: ({ connectivity, link }) => show(connectivity, link),
  });
});
  • watchNetwork watches the first service on the system bus, by NameHasOwner: NetworkManager, then iwd, then wpa_supplicant. With none, it watches NetworkManager. It does not switch if another starts later.
  • To force one, call its watch, which takes the same arguments:

| Export | Service | Reads | |---|---|---| | networkmanager watchNetworkManager | org.freedesktop.NetworkManager | connectivity; link is None, Wired, Wifi or Other (VPNs and the rest) | | iwd watchIwd | net.connman.iwd | the connected station's network; signal from GetOrderedNetworks | | wpa-supplicant watchWpaSupplicant | fi.w1.wpa_supplicant1 (only with -u) | the current BSS of an interface that is completed or rekeying (group_handshake) |

  • iwd and wpa_supplicant know only Wi-Fi: connectivity is always Unknown, and link is Wifi or None, even with a cable plugged in.
  • strength is 0 through 1. Both grade dBm as NetworkManager does: -100 dBm is 0, -40 dBm is 1. iwd's signal changes after each scan.
  • Reports once, then after each change the service signals.
  • An Err is a D-Bus failure, such as the service not running.
  • A bug or an unexpected reply shape throws, logged to the console.

Wi-Fi

import { connectWifi, watchWifi } from "@domicile-desktop/system-network/wifi";

const stop = watchWifi(host, (wifi) => {
  wifi.match({
    Err: () => hide(),
    Ok: (found) => found.match({ None: () => hide(), Some: (device) => show(device) }),
  });
});
await connectWifi(host, device, network, "passphrase");
  • watchWifi watches the first Wi-Fi device of NetworkManager, else iwd, by NameHasOwner. None is no device, or neither service. wpa_supplicant is not controlled.
  • Requests: setWifiEnabled, scanWifi, connectWifi, disconnectWifi. Each resolves Ok once the service accepts it; the watch reports the outcome.
  • connectWifi uses a network's saved profile when it has one. A new secured network needs a passphrase:
    • NetworkManager: a new WPA-PSK profile, saved.
    • iwd: iwctl --passphrase … station <interface> connect <ssid>, since iwd asks an agent for it and a page cannot serve one. iwctl must be on the compositor's PATH.
  • NetworkManager reads re-run on each property change of an object read, an access point coming or going, or a device coming or going. It does not say when a scan runs, so scanning is always false.
  • iwd does not report addresses, so connection.ip is undefined.

See SHELL-SYSTEM-ACCESS.md.

Test

bun run turbo test --filter @domicile-desktop/system-network

Tests replay D-Bus replies, in the compositor's JSON, through an injected System.