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

cartridges

v1.1.0

Published

Open source dataset of all known ammunition cartridges.

Downloads

112

Readme

pipeline status

Open Source Cartridge Dataset

A community-maintained dataset of ammunition cartridge information for use by developers, engineers, data scientists, and anyone who might find it useful.

Status

This project is a work-in-progress. To date, only the names of SAAMI cartridges are listed in the dataset.

Contributions are very welcome, and encouraged!

Installation

NodeJS

npm install cartridges

Python

Coming soon

Usage

NodeJS

const cartridges = require('cartridges');

console.log('Rimfire cartridge names:', cartridges.names.rimfire);
console.log('Cartridge details:', cartridges.rimfire.saami['22 Long']);

Python

Coming soon

Overview

Categories

Cartridges have a lot of variation, which presents some challenges for accurate and maintainable categorization. For the sake of simplicity, we use the following as top-level categories:

  • Pistol
  • Rifle
  • Rimfire
  • Shotshell

They aren't perfect, but most cartridges should be immediately recognizable as one of these. We've gotta start somewhere.

Structure

For each category above, there is a section within the top-level cartridges.json file listing cartridge names, as well as a directory containing separate JSON files for cartridges defined by each standardization body (e.g. saami.json). These separate JSON files will contain relevant information about the cartridges, according to the format below.

Format

Work In Progress

The following template should be used when adding a cartridge to the dataset. This template may evolve over time and backward-compatibility should be maintained to the best of our abilities. Language-specific packages based off of this dataset should use semantic versioning to ensure that format changes don't break userspace.

Units of measure

Cartridges are often defined in both the Metric and Imperial units of measure. In order to provide maximum flexibility, both units must be provided in the specification file.

{
  "name": "<official cartridge name>",
  "names": [
    "<other names for this cartridge>"
  ],
  "diameter_mm": "<bullet diameter in millimeters>",
  "diameter_in": "<bullet diameter in inches>",
  "specs": {
    "coal_mm": "<cartridge overall length in millimeters>",
    "coal_in": "<cartridge overall length in inches>",
    "bullet": {},
    "case": {},
    "primer": {}
  },
  "standard": "<name of body/org who maintains the spec (e.g.: SAAMI, NATO, CIP, proprietary)>",
  "references": [
    "<urls to the sources of the information provided here>"
  ]
}

References