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

@webtides/element-js-ssr-renderer

v0.1.0

Published

Server-side rendering for @webtides/element-js custom elements. Recursively pre-renders custom elements in an HTML string — emitting Declarative Shadow DOM for shadow components — so they hydrate in the browser instead of rendering from scratch.

Readme

@webtides/element-js-ssr-renderer

Server-side rendering for @webtides/element-js custom elements.

Give it an HTML string (typically the rendered output of Astro / SvelteKit / Nuxt) and it recursively pre-renders every custom element it can resolve in place — emitting Declarative Shadow DOM for shadow components, rendering light-DOM components into the element, and carrying element-js' <!--template-part--> markers so the elements hydrate on the client instead of rendering from scratch. Components load eagerly from a static catalog, or lazily so only the components actually on the page ever load.

📖 Documentation

Full documentation lives at https://webtides.github.io/element-js-ssr-renderer/:

Install

npm install @webtides/element-js-ssr-renderer

Requires @webtides/element-js >= 1.2.11 (peer dependency) and Node >= 20.19.

Quick start

import "@webtides/element-js-ssr-renderer/dom-shim"; // MUST be first — installs HTMLElement etc. for Node
import { renderToString } from "@webtides/element-js-ssr-renderer";
import Button from "@webtides/element-library/button";
import InputField from "@webtides/element-library/input-field";

const html = await renderToString(
  '<el-button variant="primary">Save</el-button>',
  {
    resolve: { "el-button": Button, "el-input-field": InputField },
  },
);

Import order matters. Component classes are class … extends HTMLElement, evaluated at import time, so @webtides/element-js-ssr-renderer/dom-shim must be imported before any component module.

On the client, import the matching …/define (or …/all) so the elements upgrade and hydrate:

import "@webtides/element-library/button/define";

That's the floor — every component imported and listed up front. To load components lazily (the cold-start / serverless / edge win), compose multiple sources, or wire the renderer into a meta-framework, see the documentation.

Examples

Runnable, self-contained apps per framework live under examples/ (Astro, Nuxt, and SvelteKit). Each SSRs the same components to Declarative Shadow DOM and hydrates them in the browser, doubling as a copy-pasteable blueprint.

License

MIT