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

siderust-js

v0.1.0

Published

Precision astronomy & satellite mechanics in safe, fast Rust.

Downloads

95

Readme

siderust-js workspace

JavaScript and WebAssembly bindings for Siderust astronomy.

This repository is the publishable JS workspace. It contains the npm packages, the shared Rust binding core used by both targets, and the Node/Web transport layers that expose the public JS API.

The public surface is strongly typed around qtty-js and tempoch-js: quantities must be passed as @siderust/qtty or @siderust/qtty-web Quantity objects, and times and windows must be passed as @siderust/tempoch or @siderust/tempoch-web JulianDate, ModifiedJulianDate, and Period objects.

Packages

| Package | Target | Status | Notes | | --- | --- | --- | --- | | @siderust/siderust | Node.js | 0.1.0 | Native addon built with napi-rs; requires @siderust/qtty and @siderust/tempoch objects at the public API boundary. | | @siderust/siderust-web | Browsers / bundlers | 0.1.0 | WebAssembly build with wasm-bindgen; requires await init() plus @siderust/qtty-web and @siderust/tempoch-web objects in the API. |

The Node and Web packages are intended to stay aligned. Platform differences are transport details, not separate domain models.

Repository layout

siderust-js/
├── siderust-core/  Shared Rust binding logic used by both targets
├── siderust-node/  Node package: @siderust/siderust
├── siderust-web/   Browser package: @siderust/siderust-web
└── scripts/        CI helpers for the Node package

What ships in 0.1.0

  • A Node package exposing observer and star models, coordinate transforms, ephemerides, altitude/azimuth event search, time-window intersection, and lunar phase helpers.
  • A browser/WASM package exposing the same astronomy surface with explicit asynchronous initialization via init().
  • A strict typed JS API that uses Quantity, JulianDate, ModifiedJulianDate, and Period at the public boundary rather than raw numbers or *Like aliases.
  • TypeScript declarations for both packages matching the runtime surface.
  • Node and Web tests, examples, and package-level READMEs for the current API.

Install

Node.js

npm install @siderust/siderust @siderust/qtty @siderust/tempoch
const { Quantity } = require('@siderust/qtty');
const { JulianDate } = require('@siderust/tempoch');
const { Observer, bodyAltitudeAt } = require('@siderust/siderust');

const observer = new Observer(
  new Quantity(-17.8925, 'Degree'),
  new Quantity(28.7543, 'Degree'),
  new Quantity(2396, 'Meter'),
);

const altitude = bodyAltitudeAt(
  'Sun',
  observer,
  new JulianDate(2451545.0).toModifiedJulianDate(),
);

console.log(altitude.value, altitude.unit);

Browser / WebAssembly

npm install @siderust/siderust-web @siderust/qtty-web @siderust/tempoch-web
import { init as initQtty, Quantity } from '@siderust/qtty-web';
import { init as initTempoch, JulianDate } from '@siderust/tempoch-web';
import { init, vsop87Heliocentric } from '@siderust/siderust-web';

await initQtty();
await initTempoch();
await init();

const mars = vsop87Heliocentric('Mars', new JulianDate(2451545.0));
console.log(mars.x.to('Kilometer').value);

Development

Clone the repository:

git clone [email protected]:Siderust/siderust-js.git
cd siderust-js

Node package workflow

cd siderust-node
npm ci
npm run build:debug
npm test

The repository also exposes CI helpers:

./scripts/ci.sh all

Web package workflow

siderust-web uses wasm-pack:

cd siderust-web
wasm-pack build --target web --out-dir pkg --release --scope siderust
npm test

Related documentation

License

AGPL-3.0. See LICENSE.