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

@tracescout/vite-plugin

v1.0.1

Published

TraceScout Vite/Rollup plugin — per-chunk debug-ID injection and private source-map upload for stack-trace symbolication.

Readme

@tracescout/vite-plugin

TraceScout Vite (and plain Rollup) plugin — per-chunk debug-ID injection and private source-map upload for stack-trace symbolication.

Install

npm install --save-dev @tracescout/vite-plugin

Node.js ≥ 18.

Usage

import { defineConfig } from "vite";
import { tracescoutSourceMaps } from "@tracescout/vite-plugin";

export default defineConfig({
  plugins: [
    tracescoutSourceMaps({
      project: process.env.TRACESCOUT_PROJECT_ID,
      release: process.env.TRACESCOUT_RELEASE,
      dist: "web",
      authToken: process.env.TRACESCOUT_AUTH_TOKEN,
    }),
  ],
  build: { sourcemap: "hidden" },
});

Every production build then:

  1. injects a deterministic per-chunk debug ID into each emitted JS chunk AND its source map (multiple chunks and dynamic imports each get their own ID — never one ID per build),
  2. publishes the entry chunk's ID for the TraceScout Browser SDK (window.__TRACESCOUT_DEBUG_ID__, injected into the HTML <head> so it is set before TraceScout.init() runs),
  3. uploads every map privately to TraceScout after a successful build, through the same shared upload core as @tracescout/cli (retries, backoff, idempotency, secret redaction).

build.sourcemap: "hidden" is recommended: maps are generated for upload but never referenced from — or served with — your deployed bundles.

Options

| Option | Meaning | Default | |---|---|---| | project | TraceScout project id | TRACESCOUT_PROJECT_ID | | release | Release identifying this build | TRACESCOUT_RELEASE | | dist | Build variant | TRACESCOUT_DIST | | authToken | Scoped upload token | TRACESCOUT_AUTH_TOKEN | | apiUrl | API base | https://api.tracescout.com | | urlPrefix | Artifact URL identity prefix | ~/ | | sourcesContentPolicy | strip | retain | reject | server default (strip) | | upload | false = inject only | true | | deleteMapsAfterUpload | Delete local .map files after a FULLY successful upload (never after a failure) | false | | errorHandling | "warn" keeps the build green; "error" fails the build on upload failure | "warn" | | uploadInWatch | Upload during watch builds | false (dev/watch never uploads) | | dryRun, quiet, debug, concurrency, timeoutMs, retries | As in the CLI | — |

Notes

  • Chunk filenames (hashes) are computed before injection and are preserved; the file content changes only by appended comments — line numbers are unchanged, so source maps stay aligned.
  • Works as a plain Rollup plugin too (standard generateBundle/closeBundle hooks); the HTML head injection applies only when an HTML asset is emitted.
  • The auth token is never logged; upload errors are redacted.

Docs: https://docs.tracescout.com/docs/guides/source-maps

License

Apache-2.0. TraceScout names and logos are trademarks of TraceScout — no trademark rights are granted.