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

@useblok/render

v0.1.1

Published

SSR-friendly renderer for Blok JSON pages. Docs: https://docs.useblok.dev

Downloads

87

Readme

@useblok/render

Headless, SSR-friendly renderer for Blok JSON. Ship published pages without pulling in the editor, drag-and-drop, or the Zustand store.

Why

@useblok/core is the editor. For production pages — Next.js App Router, React Server Components, static export — you only need the render path. @useblok/render is ~1 KB gzipped and has no runtime dependency on the editor.

Install

npm install @useblok/render @useblok/core

Quickstart

import { BlokRender } from "@useblok/render";
import { config } from "./blok.config";
import type { Data } from "@useblok/core";

export default async function Page() {
  const data: Data = await loadFromCMS();
  return <BlokRender config={config} data={data} />;
}

Works inside React Server Components. No "use client" required unless a block's render needs it.

API

<BlokRender config data />

Top-level renderer. Applies config.root.render (if any) and renders data.content.

| Prop | Type | Notes | | --------------- | ---------------------------------------------- | --------------------------------------------------------------------- | | config | Config | Same config you pass to <Blok />. | | data | Data | { root, content, zones } — the Blok document JSON. | | fallback | (type, block) => ReactNode | Optional. Rendered when a block type isn't registered in config. | | errorBoundary | boolean | Default true. Wraps each block; on throw, renders null. | | onError | (error, block) => void | Called when a wrapped block throws. Pair with your error logger. |

<BlokZone config data zoneId />

Render a single zone — useful inside custom root components or for rendering just a specific slot.

<BlokZone config={config} data={data} zoneId={slotZoneId(blockId, "children")} />

BlokRenderContext

The blok prop every block renderer receives:

interface BlokRenderContext {
  id: string;
  renderSlot: (fieldName: string) => ReactNode;
}

slotZoneId(blockId, fieldName) · ROOT_ZONE

Helpers matching @useblok/core's zone naming. Use when you need to look into data.zones directly.

SSR notes

  • The renderer itself is synchronous and has no useEffect/useState — it streams cleanly.
  • Error boundaries use getDerivedStateFromError, which runs in SSR. A thrown block renders as null instead of breaking the stream (when errorBoundary: true, the default).
  • Block render functions are your code. If a block uses browser-only APIs, gate it inside that block, not here.