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

@lynx-js/lynxtron

v0.0.3

Published

lynxtron npm package test

Readme

Lynxtron Front Package

A minimal npm package that distributes the Lynxtron runtime and exposes TypeScript type definitions with a simple CLI entry.

Installation & Usage

  • Requires Node.js >=16
  • Install:
npm install lynxtron
# or
pnpm add lynxtron
  • CLI:
npx lynxtron <args>
  • Fuse CLI:
npx lynxtron-fuses read
npx lynxtron-fuses write runAsNode=off embeddedAsarIntegrityValidation=on onlyLoadAppFromAsar=on
npx lynxtron-fuses read --app "C:\\path\\to\\lynxtron"
npx lynxtron-fuses write --binary "C:\\path\\to\\lynxtron.exe" nodeOptions=off

When --app points at a packaged app, Lynxtron prefers the real runtime binary:

  • macOS: Contents/Frameworks/Lynxtron Framework.framework/Lynxtron Framework

  • Windows: lynxtron.dll

  • Fuse API:

import { flipFuses, FuseV1Options, FuseVersion, getCurrentFuses } from '@lynx-js/lynxtron/fuses';

await flipFuses('/Applications/Lynxtron.app', {
  version: FuseVersion.V1,
  [FuseV1Options.RunAsNode]: false,
  [FuseV1Options.EnableEmbeddedAsarIntegrityValidation]: true,
  [FuseV1Options.OnlyLoadAppFromAsar]: true,
});

console.log(await getCurrentFuses('/Applications/Lynxtron.app'));
console.log(await getCurrentFuses('C:\\path\\to\\lynxtron'));

Files (excluding apis/)

  • package.json — ESM config (type: "module"), bin entry, types entry, postinstall, dependencies, publish files.
  • fuses.js — Reads and flips Lynxtron fuse bytes embedded in the packaged runtime.
  • fuses-cli.js — CLI wrapper for reading and writing fuse values.
  • install.js — Postinstall script to download and extract the runtime to dist/<platform>/<arch>/; sets executable permission on macOS.
  • lynxtron_bin.js — Resolves the platform-specific executable path under dist/<platform>/<arch>/<exe>.
  • utils/env-config.js — Resolves platform, arch and version; builds the executable filename for each OS.
  • utils/download.js — Download helper using node-fetch with timeout and single-write to disk.
  • scripts/scan-cjk-comments.js — Dev utility to scan Chinese comments outside front (not published).

Type Definitions

  • Types entry: ./apis/lynxtron.d.ts

Multi-Environment Support

Lynxtron supports both Desktop (Node.js/Electron) and Web (Browser) environments. To ensure compatibility, use the correct import paths:

  • Main Process (Desktop): import { app, LynxWindow } from '@lynx-js/lynxtron'
  • Web Host (Browser): import { setupSymmetricHost } from '@lynx-js/lynxtron/web-host'
  • Worker / Preload (Cross-Platform): import { contextBridge } from '@lynx-js/lynxtron/context-bridge'

Context Bridge

When writing code that runs in the Lynx Background Thread (e.g., preload scripts or adapters), always import contextBridge from the subpath to ensure the correct implementation is loaded for the target environment (Native Module for Desktop, Polyfill for Web).

import { contextBridge } from '@lynx-js/lynxtron/context-bridge';

contextBridge.exposeInLynxBTS({
  // ...
});