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 🙏

© 2024 – Pkg Stats / Ryan Hefner

dude-where-is-my-planet

v0.4.0

Published

Fetch state vectors for Solar System bodies from the JPL HORIZONS on-line solar system data and ephemeris.

Downloads

3

Readme

JPL HORIZONS Node.js Client

Installation

npm i dude-where-is-my-planet --save

Usage

Running the below command in your terminal will give you state vectors for the Sun and Uranus system between 2001-01-01 and 2001-01-02 and save them to a json file called sunUranusSystem.

  fetch-bodies --bodies Sun  Uranus --center Sun --units AU-D --step "1 d" --start 2001-01-01 --stop 2001-01-02 --save sunUranusSystem

Your operating system does not support shebangs?

If your operating system does not support shebangs, you will simply have to run the fetch-bodies script the way you would any npm script, like so:

  npm run fetch-bodies -- --bodies Sun  Uranus --center Sun --units AU-D --step "1 d" --start 2001-01-01 --stop 2001-01-02 --save sunUranusSystem

The output of this query looks as follows:

  [  
    [  
        {  
          "name":"Sun (10)",
          "date":"A.D. 2001-Jan-01 00:00:00.0000",
          "x":0,
          "y":0,
          "z":0,
          "vx":0,
          "vy":0,
          "vz":0
        },
        {  
          "name":"Sun (10)",
          "date":"A.D. 2001-Jan-02 00:00:00.0000",
          "x":0,
          "y":0,
          "z":0,
          "vx":0,
          "vy":0,
          "vz":0
        }
    ],
    [  
        {  
          "name":"Uranus (799)",
          "date":"A.D. 2001-Jan-01 00:00:00.0000",
          "x":15.37333859361431,
          "y":-12.72455315994613,
          "z":-0.2465764556735673,
          "vx":0.002471951210373022,
          "vy":0.002849962182880889,
          "vz":-0.00002140958914339345
        },
        {  
          "name":"Uranus (799)",
          "date":"A.D. 2001-Jan-02 00:00:00.0000",
          "x":15.37581022685618,
          "y":-12.72170297083339,
          "z":-0.2465979327045777,
          "vx":0.002471267458614458,
          "vy":0.002850429686759978,
          "vz":-0.00002151936487289544
        }
    ]
  ]

Status

This project is a living one and feedback and contributions are very much welcome. To contribute, create a branch and issue a pull request. If you wrote unit tests for your code, that would be much appreciated.

Development

  npm start

This project uses husky and lint staged to make sure the code being commited passes all tests and make sure unformatted code does not get commited to the repository.

Build

  npm run tsc

Unit Tests

To run all unit tests, you can run the command below in your terminal.

  npm test

Credits

Credits go to the awesome people at JPL that made the HORIZONS system available to the public.