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

@squawk/types

v0.8.6

Published

Shared TypeScript type definitions for the @squawk aviation libraries

Readme

MIT License npm TypeScript

Shared TypeScript type definitions used across multiple @squawk packages. Contains types for core domain models that cross the logic/data/build-script boundary: aircraft, position, airports, navaids, fixes, airways, procedures, airspace, and aircraft registration.

Domain-specific types that are produced and consumed by a single package live in that package instead:

  • Weather types (METAR, TAF, SIGMET, AIRMET, PIREP) are exported by @squawk/weather
  • NOTAM types (ICAO and FAA domestic) are exported by @squawk/notams

Documentation

Part of the @squawk aviation library suite. See all packages on npm.

Installation

npm install @squawk/types

Usage

import type { Aircraft, Position, Airport, Navaid, Fix } from '@squawk/types';

All types are re-exported from the package root. See the documentation for the full reference.

Exported types by domain

| Domain | Types | | --------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | Aircraft (ADS-B) | Aircraft, AircraftCategory | | Position | Position, Coordinates | | Airport | Airport, Runway, RunwayEnd, IlsSystem, AirportFrequency, FacilityType, OwnershipType, FacilityUseType, FacilityStatus, SurfaceCondition, SurfaceTreatment, RunwayLighting, RunwayMarkingType, RunwayMarkingCondition, VgsiType, IlsCategory, IlsSystemType | | Navaid | Navaid, NavaidType, NavaidStatus | | Fix | Fix, FixUseCode, FixCompulsory, FixNavaidAssociation | | Airway | Airway, AirwayWaypoint, AirwayType, AirwayRegion, AirwayWaypointType | | Airspace | AirspaceFeature, AirspaceType, ArtccStratum, AltitudeBound, AltitudeReference | | Procedure | Procedure, ProcedureType, ApproachType, ProcedureLeg, ProcedureLegPathTerminator, ProcedureLegFixCategory, ProcedureTransition, ProcedureCommonRoute, MissedApproachSequence, AltitudeConstraint, AltitudeConstraintDescriptor, SpeedConstraint, SpeedConstraintDescriptor, TurnDirection | | Aircraft registration | AircraftRegistration, AircraftType, EngineType |

The package also re-exports source-code lookup maps (FACILITY_TYPE_MAP, NAVAID_TYPE_MAP, AWY_TYPE_MAP, ATS_TYPE_MAP, AIRWAY_REGION_MAP, FIX_USE_CODE_MAP, FIX_COMPULSORY_MAP, NAVAID_STATUS_MAP, ILS_CATEGORY_MAP, ILS_SYSTEM_TYPE_MAP) used by the FAA NASR build pipelines to translate raw source-data values to the typed unions above. See the TypeDoc reference for full per-type signatures and field-level documentation.

Type guards

For the user-facing string-literal union types - the ones that flow in from URL params, config files, or MCP tool inputs - the package ships an is<Name> predicate paired with a <NAME>S const array as the single source of truth. Use the predicate to narrow an external string into the union without hand-rolling the membership list per consumer; use the const array as the value-side iteration target (e.g. building a lookup table keyed by the union):

import {
  AIRSPACE_TYPES,
  ARTCC_STRATA,
  FACILITY_TYPES,
  AIRWAY_TYPES,
  NAVAID_TYPES,
  FIX_USE_CODES,
  isAirspaceType,
  isArtccStratum,
  isFacilityType,
  isAirwayType,
  isNavaidType,
  isFixUseCode,
} from '@squawk/types';

const raw = new URLSearchParams(window.location.search).get('type') ?? '';
if (isAirspaceType(raw)) {
  // raw is now narrowed to AirspaceType
}

The arrays are branded with as const satisfies readonly <Type>[], so adding a new union member without updating the array fails the build.