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

@madenowhere/phaze-tsplugin

v0.0.2

Published

TypeScript language-service plugin that teaches the IDE about Phaze JSX `use:` directives — suppresses TS6133 'unused binding' diagnostics when the binding is consumed by a `use:X` JSX attribute.

Downloads

243

Readme

@madenowhere/phaze-tsplugin

TypeScript language-service plugin that teaches editors (VS Code, etc.) about Phaze JSX use:directive attributes — silences false-positive "unused binding" diagnostics when an import is consumed only via a use:NAME JSX attribute.

The problem

phaze-compile rewrites this:

<input use:autofocus={true} />

into this (post-AST):

((__el) => (autofocus(__el, () => true), __el))(<input />)

The rewritten code references autofocus like any other function call. But TypeScript's source-level analysis only sees the use:autofocus JSX namespaced attribute — which it doesn't count as a variable reference. With noUnusedLocals: true (or VS Code's "show unused" hints), the editor flags the import as unused even though it's the canonical consumer for the directive.

What this plugin does

Filters out TS6133 / TS6192 / TS6196 diagnostics whose unused name matches a binding consumed via a use:NAME JSX attribute somewhere in the same file. Other unused-binding warnings still fire — only the directive false-positive is suppressed.

Installation

pnpm add -D @madenowhere/phaze-tsplugin

Then add to your tsconfig.json:

{
  "compilerOptions": {
    "plugins": [{ "name": "@madenowhere/phaze-tsplugin" }]
  }
}

VS Code picks it up automatically via its bundled TypeScript server. Restart the TS server (Cmd+Shift+P → "TypeScript: Restart TS Server") after first install, then any time you change tsconfig plugins.

Limitations

  • IDE only. TypeScript language-service plugins run inside the language server (editor flow). They do not affect tsc CLI behavior. If your CI runs tsc --noEmit with noUnusedLocals: true, those checks will still flag directive imports. Workarounds: scope noUnusedLocals to source files only, or use eslint-based unused-imports checking with a Phaze-aware rule.
  • Per-file scope. The plugin scans only the source file the diagnostic is emitted in. If a directive import is in a.ts and the use:NAME reference is in b.ts, the import in a.ts would still appear unused — which is correct (re-exporting through an unused intermediate file isn't a Phaze idiom).
  • Name-based matching. The plugin matches on the local binding name as it appears in TS's diagnostic message. Aliasing imports (import { autofocus as _af }) means the JSX has to use use:_af to match — TS still tracks the local name, so this works as expected.