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

@stackra/zones

v3.0.0

Published

Zone / slot extensibility runtime for the Stackra framework — DI-owned zone registry, before/after/replace ordering, React + native bindings for <Zone> / <FormFieldZone> / <TableColumnZone>.

Readme

@stackra/zones

Zone / slot extensibility runtime for the Stackra framework. Provides a DI-owned ZoneRegistry, a pure resolveZoneOrder(...) ordering algorithm, and React + React Native bindings for <Zone>, <FormFieldZone>, and <TableColumnZone>.

Install

Workspace consumers:

// package.json
{
  "peerDependencies": {
    "@stackra/zones": "workspace:^",
  },
}

External consumers:

pnpm add @stackra/zones

Usage

General <Zone>

Host page declares a zone with intrinsic children; other modules contribute into it through <HostModule>.forFeature({ zones: [...] }).

// packages/frontend/user/src/react/pages/users-list/users-list.page.tsx
import { Zone } from "@stackra/zones/react";

export function UsersListPage() {
  return (
    <div>
      <Zone id="users.list.header">
        <SearchInput id="search" />
        <ExportButton id="export" />
      </Zone>
      <UsersTable />
    </div>
  );
}

Form-field zone

Host page owns the form; <FormFieldZone> produces the ordered field descriptor list; the host renders the fields any way it wants.

// packages/frontend/user/src/react/pages/user-create/user-create.page.tsx
import { FormFieldZone } from "@stackra/zones/react";

export function UserCreatePage() {
  const intrinsic = [
    { name: "email", label: "Email", kind: "email", required: true },
    { name: "name", label: "Name", kind: "text", required: true },
  ];

  return (
    <FormFieldZone id="user.create.form" intrinsicFields={intrinsic}>
      {(fields) => (
        <Form>
          {fields.map((f) => (
            <FieldRenderer key={f.name} descriptor={f} />
          ))}
        </Form>
      )}
    </FormFieldZone>
  );
}

Contribute a React component into a zone

// packages/frontend/audit/src/react/web-audit.module.ts
import { UserModule } from "@stackra/user";

@Module({})
export class WebAuditModule {
  public static forRoot(): DynamicModule {
    return {
      module: WebAuditModule,
      imports: [
        UserModule.forFeature({
          zones: [
            {
              id: "audit-users-header-badge",
              zone: "users.list.header",
              kind: "react",
              position: "end",
              when: (ctx) => ctx.permissions.includes("audit.view"),
              component: AuditBadge,
            },
          ],
        }),
      ],
    };
  }
}

SDUI Zone node

Schemas reference type: "Zone" and place intrinsic children in the intrinsic slot. Contributions come from the DI-owned ZoneRegistry.

{
  "id": "landing-top-zone",
  "type": "Zone",
  "props": { "zoneId": "landing.top" },
  "slots": {
    "intrinsic": [
      { "id": "hero", "type": "Hero", "props": { "headline": "Welcome" } }
    ]
  }
}

Subpaths

  • @stackra/zones — core: ZonesModule, ZoneRegistry, resolveZoneOrder(...), cross-platform types.
  • @stackra/zones/react — web bindings: WebZonesModule, <Zone>, <FormFieldZone>, <TableColumnZone>, useZone, useZoneContext.
  • @stackra/zones/native — RN counterparts, same public API.
  • @stackra/zones/testingMockZoneRegistry, TestZonesProvider, canned contributions.

Cross-references

  • .kiro/specs/zones/design.md — the design of record.
  • .kiro/specs/zones/tasks.md — the implementation task list.
  • .kiro/steering/module-lifecycle.md §"forFeature — always via an @Injectable() registrar class" — ADR-0052 canonical shape.
  • .kiro/steering/subpath-layering.md — subpath dependency direction.
  • @stackra/contracts/interfaces/zones — shared contract vocabulary.
  • @stackra/sdui — SDUI Zone component + section-style resolver.