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

poli-qa

v1.0.0

Published

POLI - Portable Overlay for Live Inspection. A QA testing overlay for React apps with CLI auto-detection.

Readme

POLI - Portable Overlay for Live Inspection

🦜 A QA testing overlay for React applications. Add manual testing checklists, bug reporting, and test session management to any React app.

Features

  • 🔍 Auto-Detection CLI - Scans your project and generates test checklists automatically
  • 🧪 Test Checklists - Define tests per screen, mark as pass/fail/skip
  • 🐛 Bug Reporting - Report bugs with severity, steps to reproduce, expected/actual behavior
  • 📊 Test Sessions - Track testing progress across sessions
  • 💾 Persistent State - Auto-saves to localStorage
  • 📥 Export Reports - Generate Markdown reports
  • ⌨️ Keyboard Shortcut - Toggle with Ctrl+Shift+Q (Cmd+Shift+Q on Mac)
  • 🎨 Draggable Panel - Position anywhere on screen
  • 🚫 No CSS Dependencies - All styles are inline, works without Tailwind

Installation

npm install poli-qa

Quick Start with CLI (Recommended)

The easiest way to get started is using the CLI to auto-detect your screens:

# Scan your project and generate test checklists
npx poli-qa init

This will:

  1. Scan your src/ folder for screen/page components
  2. Generate a poli.checklists.ts file with suggested tests
  3. Give you instructions on how to integrate POLI

Then in your app:

import { QAProvider, QAPanel } from 'poli-qa';
import { checklists } from './poli.checklists';

function App() {
  return (
    <QAProvider defaultChecklists={checklists}>
      <YourApp />
      <QAPanel />
    </QAProvider>
  );
}

CLI Commands

npx poli-qa init          # Scan project and generate checklists
npx poli-qa scan          # Preview detected screens without generating
npx poli-qa add <screen>  # Add a new screen manually
npx poli-qa help          # Show help

What the CLI Detects

The CLI looks for files matching these patterns:

  • *Page.tsx, *Screen.tsx, *View.tsx
  • Files in pages/, screens/, views/, routes/ directories

It then analyzes the code to suggest relevant tests based on:

  • Forms, inputs, validation
  • Authentication flows
  • Data fetching and loading states
  • Navigation and modals
  • And more...

Manual Setup

npm install poli-qa

Manual Setup (Without CLI)

If you prefer to define checklists manually:

import { QAProvider, QAPanel } from 'poli-qa';
import type { TestChecklist } from 'poli-qa';

// Define your app's screens
type AppScreen = 'HOME' | 'DASHBOARD' | 'SETTINGS' | 'PROFILE';

// Define test checklists for each screen
const checklists: TestChecklist<AppScreen>[] = [
  {
    screen: 'HOME',
    items: [
      {
        id: 'home_001',
        screen: 'HOME',
        category: 'UI',
        description: 'Hero section loads with correct content',
        status: 'not_started',
      },
      {
        id: 'home_002',
        screen: 'HOME',
        category: 'Functionality',
        description: 'CTA button navigates to signup',
        status: 'not_started',
      },
    ],
  },
  {
    screen: 'DASHBOARD',
    items: [
      {
        id: 'dash_001',
        screen: 'DASHBOARD',
        category: 'UI',
        description: 'Dashboard shows user stats',
        status: 'not_started',
      },
    ],
  },
];

function App() {
  return (
    <QAProvider defaultChecklists={checklists}>
      {/* Your app components */}
      <YourApp />

      {/* Add the QA panel */}
      <QAPanel />
    </QAProvider>
  );
}

API Reference

<QAProvider>

Wrap your app with QAProvider to enable POLI.

<QAProvider
  defaultChecklists={checklists}  // Test checklists for your app
  storageKey="my_app_qa"          // localStorage key (default: 'poli_qa_state')
  enableScreenDetection={true}    // Auto-detect current screen (default: true)
  testerName="QA Tester"          // Default tester name
>
  {children}
</QAProvider>

<QAPanel>

The main QA panel component. Renders as a floating button when minimized.

<QAPanel />

useQA() Hook

Access QA state and functions from any component.

const {
  // State
  state,              // Full QA state
  currentScreen,      // Currently detected screen
  isOpen,             // Panel visibility

  // Panel control
  togglePanel,
  openPanel,
  closePanel,

  // Screen detection
  setCurrentScreen,   // Manually set current screen

  // Test management
  updateTestStatus,   // (testId, status, notes?) => void
  addTestItem,        // Add a test dynamically
  removeTestItem,     // Remove a test

  // Bug reporting
  reportBug,          // Report a new bug
  updateBugStatus,    // Update bug status
  deleteBug,          // Delete a bug

  // Sessions
  startTestSession,   // (name, tester) => void
  completeTestSession,// (notes?) => void
  deleteSession,      // Delete a past session

  // Export
  generateMarkdownReport, // Returns string
  exportState,        // Downloads .md file
  resetState,         // Reset all state
} = useQA();

Screen Detection

Manually tell POLI which screen the user is on:

function MyScreen() {
  const { setCurrentScreen } = useQA();

  useEffect(() => {
    setCurrentScreen('DASHBOARD');
    return () => setCurrentScreen(null);
  }, []);

  return <div>Dashboard content</div>;
}

Or create a custom hook:

function useScreen(screen: AppScreen) {
  const { setCurrentScreen } = useQA();

  useEffect(() => {
    setCurrentScreen(screen);
    return () => setCurrentScreen(null);
  }, [screen, setCurrentScreen]);
}

// Usage
function DashboardScreen() {
  useScreen('DASHBOARD');
  return <div>Dashboard</div>;
}

Test Item Structure

interface TestItem {
  id: string;                    // Unique identifier
  screen: string;                // Screen this test belongs to
  category: 'UI' | 'Functionality' | 'Performance' | 'Integration';
  description: string;           // What to test
  status: 'not_started' | 'passed' | 'failed' | 'skipped';
  notes?: string;                // Tester notes
  testedAt?: number;             // Timestamp when tested
}

Bug Report Structure

interface BugReport {
  id: string;
  title: string;
  description: string;
  severity: 'critical' | 'high' | 'medium' | 'low';
  status: 'open' | 'in_progress' | 'fixed' | 'wont_fix';
  screen: string;
  stepsToReproduce: string[];
  expectedBehavior: string;
  actualBehavior: string;
  reportedAt: number;
  reportedBy: string;
}

Keyboard Shortcuts

  • Ctrl+Shift+Q (Windows/Linux) or Cmd+Shift+Q (Mac) - Toggle panel visibility

Styling

POLI uses inline styles and has no external CSS dependencies. It works with any React app regardless of styling solution (Tailwind, CSS Modules, styled-components, etc.).

The panel is fixed positioned with z-index 9999 to ensure it overlays your app.

Development

# Install dependencies
npm install

# Build the package
npm run build

# Watch mode
npm run dev

License

MIT