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

@ofi-data-team/transect-research-map

v0.1.3

Published

Embeddable MapLibre map of TranSECT research locations.

Readme

TranSECT Research Map

A focused, full-viewport MapLibre map of TranSECT research locations. The map is packaged as an embeddable <transect-research-map> Web Component and uses the visual language established by the TCA cruise trajectory map.

Install

npm install @ofi-data-team/transect-research-map

Import the component and its host-page styles:

import '@ofi-data-team/transect-research-map';
import '@ofi-data-team/transect-research-map/style.css';

The package includes its runtime datasets under data/. Copy that directory to a location served by your application, then point data-src at the copied JSON file.

Develop

npm install
npm run dev

Validate and test

npm run validate:data
npm run test:unit
npm run test:e2e

The browser uses structured JSON and referenced GeoJSON files from data/. scripts/validate-data.ts checks the dataset before it is displayed.

Download Native Land GeoJSON

Create a free Native Land Digital API key, read and accept its Indigenous Data Sovereignty Treaty, and save the key in .env at the project root:

NATIVE_LAND_API_KEY=your-key

The downloader reads this file automatically. A value exported in the shell takes precedence. Run an area or point download without putting the key on the command line:

npm run download:native-land -- \
  --position "44.6488,-63.5752" \
  --output data/geojson/halifax-native-land.geojson

For an area rather than a point, pass an existing Polygon, MultiPolygon, Feature, or FeatureCollection. The script sends it to Native Land Digital's polygon-intersection endpoint:

npm run download:native-land -- \
  --polygon data/geojson/annapolis-valley.geojson \
  --output data/geojson/annapolis-valley-native-land.geojson

Use --name <slug> for a specific nation or --all for a complete category. Run npm run download:native-land -- --help for every option. The output keeps the API geometry unchanged and adds Native Land Digital attribution, a non-legal-boundary disclaimer, and the download timestamp. Do not commit or share the API key. Native Land Digital's current terms limit API use and require attribution; review the treaty before storing or distributing downloaded data.

Embed

After importing the package, add the component:

<transect-research-map data-src="/TranSECT-mapDb.mock.json"></transect-research-map>

Give the component an explicit height through CSS. Relative GeoJSON references are resolved against data-src. During development and builds, Vite serves the contents of data/ from the site root.

Configuration

Static map settings live in src/config.ts. Edit MAP_CONFIG.lines.location to change the normal boundary color, width, or opacity, and MAP_CONFIG.lines.selected to change the selected boundary. The same file contains the default data source, basemap, viewport, zoom, padding, and interaction timing values.

The interface defaults to English and includes an EN/FR switch in the top-left corner. Set lang="fr" on the component when it should initially render in French:

<transect-research-map lang="fr" data-src="/TranSECT-mapDb.mock.json"></transect-research-map>

License

MIT