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

@azure-utils/storybooks

v0.2.2

Published

Utils to upload and manage Storybooks via Azure Functions and storage.

Downloads

13

Readme

Azure Functions Storybooks management Router

An easy way to deploy Storybooks management using Azure Functions. The package registers all endpoints required for upload, delete and serve storybooks.

Only works with V4 functions written in TypeScript/JavaScript.

DOCS • Packages: NPM JSR

Install

NPM

npm i @azure-utils/storybooks

JSR

npx jsr add @azure-utils/storybooks
yarn add jsr:@azure-utils/storybooks

Build and deploy app

The package exports a registerStorybooksRouter function which registers all endpoint required.

Register the router

Invoke the registration function is a file that is covered by Azure Functions. Normally this is the index.js file. The function takes an optional options argument which can be used override default settings.

// index.js
import { registerStorybooksRouter } from "@azure-utils/storybooks";

registerStorybooksRouter();

-- or --

// index.js
import { registerStorybooksRouter, getStore } from "@azure-utils/storybooks";

const registerRoute = registerStorybooksRouter({
   /**
   * Define the route on which all router is placed.
   *
   * @default 'storybooks/'
   */
  route?: string;

  /**
   * The function HTTP authorization level Defaults to 'anonymous' if not specified.
   */
  authLevel?: HttpTriggerOptions["authLevel"];

  /**
   * Name of the Environment variable which stores
   * the connection string to the Azure Storage resource.
   * @default 'AzureWebJobsStorage'
   */
  storageConnectionStringEnvVar?: string;

  /**
   * Modify the cron-schedule of timer function
   * which purge outdated storybooks.
   *
   * Pass `null` to disable auto-purge functionality.
   *
   * @default "0 0 0 * * *" // Every midnight
   */
  purgeScheduleCron?: string | null;
});

// Register additional routes on the service
registerRoute("account", {
  route: "account",
  methods: ["GET","POST"],
  handler: (request, context) => {
    return { statue: 200 }
  }
})

Update host.json (optional)

Azure functions use host.json in app root to configure the settings for whole functions-app.

Add/update the following setting to make sure there is no (empty) prefix before routes. If left unset, then Azure Functions may add /api prefix to routes which is undesirable for clean routing.

{
  "version": "2.0",
  "extensionBundle": {
    "id": "Microsoft.Azure.Functions.ExtensionBundle",
    "version": "[4.*, 5.0.0)"
  },
  "extensions": {
    "http": {
      "routePrefix": ""
    }
  }
}

Deploy app

In order to deploy the app by CLI, CI or Azure plugin, you a need an Azure Functions resource in your Azure subscription.

If you are creating a new resource, select the option to create an associated Storage account, that will be used to store cache artifacts.

If your app is not connected to Storage account or you wish to override storage account, use ENV or OPTIONS to do so.

License

MIT © 2025 Siddhant Gupta (@GuptaSiddhant)