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

@react-perfscope/ui

v0.7.1

Published

In-app performance panel and overlays for react-perfscope.

Readme

@react-perfscope/ui

Floating-widget UI for react-perfscope. Mounts a Shadow-DOM-isolated panel into your page that records performance signals, shows them in a per-kind tabbed panel, and highlights affected DOM regions with overlays.

Install

npm install @react-perfscope/ui @react-perfscope/core

Usage

import { createRecorder } from '@react-perfscope/core'
import { createRenderCollector } from '@react-perfscope/react'
import { mount } from '@react-perfscope/ui'

const recorder = createRecorder()
recorder.use(createRenderCollector())

const unmount = mount({ recorder })
// ... later, to remove:
// unmount()

What's in the panel

Click any row to expand its detail. Each signal kind shows different info:

  • forced-reflow — call stack showing where layout was forced; reads in one turn are coalesced into a single entry carrying its read count
  • layout-shift — CLS value + each source rect
  • long-task — start/end/duration, plus call stack if captured
  • network — full URL, transfer size, render-blocking flag
  • web-vital — metric name, value, rating per Google thresholds
  • render — one entry per commit, showing the cascade root and every component that re-rendered

The header has a Save button that downloads the full recording as JSON. The render tab offers Group by component and the forced-reflow tab offers Group by source.

API

  • mount({ recorder, position?, host? }) — returns an unmount function.
    • position: 'bottom-right' | 'bottom-left' | 'top-right' | 'top-left'. Defaults to 'bottom-right'.
    • host: parent element for the Shadow DOM host. Defaults to document.body.
  • mountShadow(vnode, { parent? }) — mount any Preact vnode in a fresh Shadow Root. Returns unmount.
  • showOverlay(id, rect) / hideOverlay(id) / hideAllOverlays() — DOM overlay primitives.
  • App, Panel, Widget — Preact components, exported for advanced composition.

한국어

react-perfscope용 플로팅 위젯 UI. Shadow DOM으로 격리된 패널을 페이지에 마운트해서, 성능 신호를 기록하고 종류별 탭 패널로 표시하고 영향받은 DOM 영역을 오버레이로 하이라이트한다.

설치

npm install @react-perfscope/ui @react-perfscope/core

사용법

import { createRecorder } from '@react-perfscope/core'
import { createRenderCollector } from '@react-perfscope/react'
import { mount } from '@react-perfscope/ui'

const recorder = createRecorder()
recorder.use(createRenderCollector())

const unmount = mount({ recorder })
// ... 나중에 제거하려면:
// unmount()

패널 안에 뭐가 있나

신호 row를 클릭하면 디테일이 펼쳐진다. 종류별로 다른 정보를 보여준다:

  • forced-reflow — 레이아웃을 강제한 호출 스택. 한 턴에 일어난 읽기는 읽기 횟수를 담은 한 항목으로 합쳐진다
  • layout-shift — CLS 값 + 각 source rect
  • long-task — 시작/끝/duration, 캡처된 스택이 있으면 같이 표시
  • network — 전체 URL, transfer size, render-blocking 여부
  • web-vital — 메트릭 이름, 값, Google 기준에 따른 등급
  • render — 커밋당 한 항목. 캐스케이드 루트와 그 커밋에서 리렌더된 모든 컴포넌트를 보여준다

헤더의 Save 버튼으로 전체 recording을 JSON으로 받을 수 있다. render 탭에는 Group by component, forced-reflow 탭에는 Group by source 옵션이 있다.

API

  • mount({ recorder, position?, host? }) — unmount 함수를 반환한다.
    • position: 'bottom-right' | 'bottom-left' | 'top-right' | 'top-left'. 기본값은 'bottom-right'.
    • host: Shadow DOM 호스트를 붙일 부모 엘리먼트. 기본값은 document.body.
  • mountShadow(vnode, { parent? }) — 새 Shadow Root에 Preact vnode를 마운트한다. unmount 함수를 반환.
  • showOverlay(id, rect) / hideOverlay(id) / hideAllOverlays() — DOM 오버레이 기본 함수.
  • App, Panel, Widget — 고급 조합을 위해 export된 Preact 컴포넌트들.