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

svelte-adapter-fastify-std

v0.1.3

Published

Adapter for SvelteKit apps that generates a standalone Node Fastify server

Downloads

3

Readme

SvelteKit adapter for Fastify

This is an adapter for SvelteKit that builds your app as a standalone Node.js server using Fastify.

Usage

Install with your package manager of choice:

pnpm add -D adapter-fastify

Then add the adapter to your svelte.config.js:

// filepath: svelte.config.js
import adapter from 'adapter-fastify';

/** @type {import('@sveltejs/kit').Config} */
const config = {
    kit: {
        adapter: adapter()
    }
};

export default config;

Options

The adapter supports the following options:

// filepath: svelte.config.js
// ...
const config = {
    kit: {
        adapter: adapter({
            // The directory to build the server to.
            // It is relative to the project root.
            out: 'build',

            // If true, assets will be precompressed with brotli and gzip.
            precompress: true,

            // The prefix for environment variables that should be exposed to the client.
            envPrefix: ''
        })
    }
};
// ...

Runtime Configuration (Environment Variables)

The behavior of the deployed server can be controlled with the following environment variables:

  • HOST: The host to listen on. Defaults to 0.0.0.0.
  • PORT: The port to listen on. Defaults to 3000.
  • SOCKET_PATH: If set, the server will listen on a UNIX socket at this path instead of a TCP port.
  • USE_HTTP2: Set to 'true' to enable HTTP/2. Defaults to 'false'.
  • HTTPS_KEY_PATH: Path to the SSL private key file. Required if USE_HTTP2 is true.
  • HTTPS_CERT_PATH: Path to the SSL certificate file. Required if USE_HTTP2 is true.
  • LOGGER: Set to 'true' to enable Fastify's built-in logger. Defaults to 'false'.
  • SHUTDOWN_TIMEOUT: The time in seconds to wait for connections to close before forcefully shutting down. Defaults to 30.
  • IDLE_TIMEOUT: For systemd socket activation, the time in seconds to wait for a new request before shutting down. Defaults to 0 (disabled).
  • LISTEN_PID, LISTEN_FDS: For systemd socket activation. See the systemd documentation for more details.

Building and running the server

You can build your app by running the build script, which is usually present in your package.json:

pnpm build

This will create a server in the build directory (or the directory specified in the out option). You can then run the server with:

node build/index.js

License

This project is licensed under the MIT License. See the LICENSE file for details.