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

@aurumjs/vite-plugin

v0.10.0

Published

Vite build policy for Aurum developer tooling metadata

Downloads

122

Readme

@aurumjs/vite-plugin

Vite build policy for Aurum developer tooling. Development builds retain rich data-flow metadata such as source allocation stacks. Production builds keep the lightweight graph instrumentation required by the browser extension while omitting expensive metadata by default.

Setup

// vite.config.ts
import { defineConfig } from 'vite';
import { aurumDevtools } from '@aurumjs/vite-plugin';

export default defineConfig({
    plugins: [aurumDevtools()]
});

The default auto policy resolves as follows:

| Vite invocation | Aurum mode | Stack capture | Instrumentation | | ----------------------- | ------------ | ------------- | --------------- | | Development server | debug | Enabled | Enabled | | Production build | production | Disabled | Enabled | | Build with another mode | debug | Enabled | Enabled |

Instrumentation is not disabled in production. The extension can still show the live source and subscription graph, but names, creation locations, and other debug-only metadata are omitted from Aurum's production protocol. Set instrumentation: false when the application should compile graph registration out entirely. The extension cannot inspect that build, but stream construction and subscription changes avoid all registry work.

A production build locks that policy into the runtime. Calls to runtime configuration cannot promote it back to debug mode or re-enable stack and event-history retention; use an explicit mode: 'debug' diagnostic build when those details are needed.

Explicit policy

The policy can be overridden for diagnostic builds or particularly sensitive development environments:

aurumDevtools({
    mode: 'production',
    captureStacks: false,
    instrumentation: false
});

mode accepts auto, debug, or production. captureStacks defaults to true in debug mode and can be disabled there. Production mode always forces it off so a lean build cannot accidentally retain call sites. instrumentation defaults to true and is independent of the metadata mode.

Build constants

The plugin defines these constants for Aurum's runtime packages:

  • __AURUM_DEVTOOLS_MODE__: "debug" or "production"
  • __AURUM_DEVTOOLS_CAPTURE_STACKS__: true or false
  • __AURUM_DEVTOOLS_INSTRUMENTATION__: true or false

Aurum guards reads with typeof, so running its unbundled output in Node or using another bundler does not depend on globals provided by this plugin.

Applications can inspect the resolved policy explicitly through a virtual module. Add @aurumjs/vite-plugin/client to the types array in the application's TypeScript configuration if the virtual import is used.

import config, { captureStacks, instrumentation, mode } from 'virtual:aurum-devtools/config';

The virtual module is side-effect free. Runtime configuration is selected by the compile-time constants, avoiding bootstrap ordering problems.