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

fishfyi-embed

v1.1.0

Published

Embed FishFYI aquatic widgets — fish cards, water type badges, aquarium specs, game fish ratings. Zero dependencies, Shadow DOM, 4 themes.

Readme

fishfyi-embed

npm License: MIT Zero Dependencies

Embed FishFYI widgets — fish, glossary terms, interactive tools, and inline elements — on any website. 10 widget types, zero dependencies, Shadow DOM style isolation, 4 built-in themes (light, dark, sepia, auto), 2 styles (modern, organic), and live data from the FishFYI database.

Every widget includes a "Powered by FishFYI" backlink directing readers to the full reference.

Try the interactive widget builder at widget.fishfyi.com

Quick Start

<!-- Place widget div where you want it to appear -->
<div data-fishfyi="entity" data-slug="fish" data-theme="light"></div>

<!-- Load the embed script once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/fishfyi-embed@1/dist/embed.min.js"></script>

That's it. The widget fetches data from the FishFYI API and renders with full style isolation.

Widget Types

| Type | Usage | Description | |------|-------|-------------| | entity | <div data-fishfyi="entity" data-slug="..."></div> | Entity detail card — species, bird, fish, plant, or dinosaur | | glossary | <div data-fishfyi="glossary" data-slug="..."></div> | Glossary term definition with cross-references | | guide | <div data-fishfyi="guide" data-slug="..."></div> | Guide summary card with key takeaways | | compare | <div data-fishfyi="compare" data-slug="..."></div> | Side-by-side entity comparison | | search | <div data-fishfyi="search" data-slug="..."></div> | Search box linking to the full database | | iucn-badge | <div data-fishfyi="iucn-badge" data-slug="..."></div> | IUCN conservation status badge with 9 status levels | | water-type | <div data-fishfyi="water-type" data-slug="..."></div> | Freshwater/Saltwater/Brackish colored badge | | iucn-inline | <div data-fishfyi="iucn-inline" data-slug="..."></div> | Inline IUCN status colored pill | | water-inline | <div data-fishfyi="water-inline" data-slug="..."></div> | Inline water type colored pill | | taxonomy-inline | <div data-fishfyi="taxonomy-inline" data-slug="..."></div> | Italic scientific binomial name |

Widget Options

| Attribute | Values | Default | Description | |-----------|--------|---------|-------------| | data-fishfyi | entity, compare, glossary, guide, search, [tools] | required | Widget type | | data-slug | e.g. "fish" | — | Entity slug from the FishFYI database | | data-theme | light, dark, sepia, auto | light | Visual theme (auto follows OS preference) | | data-styleVariant | modern, organic | modern | Widget design style | | data-size | default, compact, large | default | Widget size | | data-placeholder | any string | "Search Fish..." | Search box placeholder |

Themes

<!-- Light (default) -->
<div data-fishfyi="entity" data-slug="fish" data-theme="light"></div>

<!-- Dark -->
<div data-fishfyi="entity" data-slug="fish" data-theme="dark"></div>

<!-- Sepia -->
<div data-fishfyi="entity" data-slug="fish" data-theme="sepia"></div>

<!-- Auto — follows OS dark/light preference -->
<div data-fishfyi="entity" data-slug="fish" data-theme="auto"></div>

Styles

<!-- Modern (default) — clean lines, rounded corners, accent gradients -->
<div data-fishfyi="entity" data-slug="fish" data-styleVariant="modern"></div>

<!-- Organic — natural curves, earth-tone aesthetics, field-guide look -->
<div data-fishfyi="entity" data-slug="fish" data-styleVariant="organic"></div>

Web Components (Custom Elements)

As an alternative to data-* attributes, you can use native HTML custom elements:

<!-- Custom element form -->
<fishfyi-entity slug="fish" theme="light"></fishfyi-entity>
<fishfyi-compare slugs="fish,other-slug"></fishfyi-compare>
<fishfyi-search placeholder="Search Fish..."></fishfyi-search>

<script src="https://cdn.jsdelivr.net/npm/fishfyi-embed@1/dist/embed.min.js"></script>

Use style-variant (not style) to avoid conflicts with the HTML reserved style attribute.

Examples

Entity Card

<div data-fishfyi="entity" data-slug="fish" data-theme="light"></div>
<script src="https://cdn.jsdelivr.net/npm/fishfyi-embed@1/dist/embed.min.js"></script>

Side-by-Side Comparison

<div data-fishfyi="compare" data-slugs="fish,other-slug"></div>
<script src="https://cdn.jsdelivr.net/npm/fishfyi-embed@1/dist/embed.min.js"></script>

Search Box

<div data-fishfyi="search" data-placeholder="Search Fish..."></div>
<script src="https://cdn.jsdelivr.net/npm/fishfyi-embed@1/dist/embed.min.js"></script>

Glossary Term

<div data-fishfyi="glossary" data-slug="example-term" data-theme="light"></div>
<script src="https://cdn.jsdelivr.net/npm/fishfyi-embed@1/dist/embed.min.js"></script>

CDN Options

jsDelivr (recommended — global CDN, auto-updates with npm)

<script src="https://cdn.jsdelivr.net/npm/fishfyi-embed@1/dist/embed.min.js"></script>

Specific version (production stability)

<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/embed.min.js"></script>

npm (for bundlers)

npm install fishfyi-embed
import 'fishfyi-embed';

Technical Details

  • Shadow DOM: Complete style isolation — no CSS conflicts with your site
  • Zero dependencies: No jQuery, React, or any external library
  • 2 styles: Modern (accent gradients) and Organic (natural curves, field-guide aesthetic)
  • 4 themes: Light, Dark, Sepia, Auto (OS preference detection)
  • CORS: FishFYI API has CORS enabled for all origins
  • MutationObserver: Works with dynamically added elements (SPAs)
  • IntersectionObserver: Lazy loading — widgets only fetch when entering viewport (200px margin)
  • Rich Snippets: DefinedTerm JSON-LD injected for glossary widgets
  • Bundle size: Tree-shaken per site — only includes tools available on FishFYI

Learn More About Fish

Visit fishfyi.com — FishFYI is a comprehensive fish reference with interactive tools, guides, and developer resources.

Nature FYI Family

Part of FYIPedia — open-source developer tools ecosystem. Nature FYI covers species taxonomy, ornithology, marine biology, botany, and paleontology. Hub: naturefyi.com.

| Site | Domain | Focus | Package | |------|--------|-------|---------| | SpeciesFYI | speciesfyi.com | Species taxonomy, biodiversity, IUCN conservation status | npm | | BirdFYI | birdfyi.com | 11,251 birds, biometrics, conservation, habitats | npm | | FishFYI | fishfyi.com | 35,729 fish, game fishing, aquarium care, compatibility | npm | | PlantFYI | plantfyi.com | 379,774 plants, hardiness zones, bloom seasons, gardening | npm | | DinoFYI | dinofyi.com | 6,142 dinosaurs, geological periods, paleontology | npm |

License

MIT — see LICENSE.

Built with care by FYIPedia.