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

@progrest/ssr-nest

v0.0.3

Published

Wires a NestJS (Fastify) app to serve a built Angular SSR app for every route its own controllers don't own. The core "glue" behind [Progressive](https://github.com/rortizv/progressive) — Angular (SSR) + NestJS in a single Node.js process.

Readme

@progrest/ssr-nest

Wires a NestJS (Fastify) app to serve a built Angular SSR app for every route its own controllers don't own. The core "glue" behind Progressive — Angular (SSR) + NestJS in a single Node.js process.

Usually you don't install this directly — npm create progressive@latest sets it up for you. Documented here for anyone wiring it into an existing Nest app, or curious how it works.

Usage

import { NestFactory } from '@nestjs/core';
import { FastifyAdapter, NestFastifyApplication } from '@nestjs/platform-fastify';
import { mountAngularSsr } from '@progrest/ssr-nest';
import { join } from 'node:path';
import { AppModule } from './app/app.module';

async function bootstrap() {
  const app = await NestFactory.create<NestFastifyApplication>(
    AppModule,
    new FastifyAdapter(),
  );

  app.setGlobalPrefix('api');

  // `angularDistPath` is the folder containing your Angular app's `browser/`
  // and `server/` subfolders, produced by `@angular/build:application` with
  // SSR enabled.
  await mountAngularSsr(app, {
    angularDistPath: join(__dirname, '../web'),
  });

  await app.listen(process.env.PORT ?? 3000, '0.0.0.0');
}

bootstrap();

Call mountAngularSsr after registering your own controllers/modules and before app.listen(). From then on:

  • Static browser assets (JS/CSS bundles, favicon) are served directly.
  • Any route your own @Controller()s don't match falls through to Angular's AngularNodeAppEngine for SSR rendering.

If angularDistPath doesn't exist yet (e.g. you're running Angular's own dev server, which serves everything in memory and never writes to disk), mountAngularSsr logs a warning and skips mounting instead of throwing — your Nest app still starts and serves its own routes normally.

How it works

Two things NestJS does that most integrations don't expect:

  1. Nest always registers its own Fastify not-found handler on app.listen(), with no way to opt out. Instead of fighting Fastify's single setNotFoundHandler slot, mountAngularSsr installs a global exception filter that catches the NotFoundException Nest's default handler throws, and renders the Angular page there.
  2. The Angular SSR bundle is pure ESM, but a Nest app compiled to CommonJS can't require() it (ERR_REQUIRE_ESM). The bridge loads it via a real dynamic import(), kept invisible to TypeScript's commonjs-target transform.

Requires

  • @nestjs/common, @nestjs/platform-fastify, fastify ^11 / ^5 (peer dependencies — bring your own, matching your Nest app).
  • An Angular app built with SSR enabled (ssr: true / outputMode: "server" in the Angular CLI application builder).

Full write-up: github.com/rortizv/progressive.