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

@buoy-gg/zustand

v2.1.10

Published

Zustand store DevTools for React Native

Readme

@buoy-gg/zustand

Zustand store DevTools for React Native. Live state change monitoring, state inspection, and diff visualization for your Zustand stores.

Setup

npm install @buoy-gg/zustand

One line — zero store modifications

import { watchStores } from '@buoy-gg/zustand';
import { useCounterStore } from './stores/counter';
import { useAuthStore } from './stores/auth';
import { useCartStore } from './stores/cart';

// Call once at module scope (e.g. in _layout.tsx or App.tsx):
watchStores({
  counterStore: useCounterStore,
  authStore: useAuthStore,
  cartStore: useCartStore,
});

That's it. The Zustand tool appears automatically in FloatingDevTools.

Your stores stay completely untouched — watchStores uses Zustand's built-in .subscribe() to observe changes from the outside. It never modifies setState or any store internals.

Safe by design

  • Add in seconds — one import, one function call
  • Remove in seconds — delete those two lines, done
  • Cannot break your stores — all listener code is wrapped in try/catch. Even if our code has a bug, your stores keep working normally
  • No monkey-patching — we call .subscribe(), the same API your own components use

Cleanup (optional)

const cleanup = watchStores({ ... });

// Later, to stop watching:
cleanup();

Advanced: middleware mode

If you want extra detail (the exact partial passed to setState and precise timing), you can opt into the middleware approach per-store:

import { create } from 'zustand';
import { buoyDevTools } from '@buoy-gg/zustand';

const useCounterStore = create(
  buoyDevTools(
    (set) => ({
      count: 0,
      increment: () => set((s) => ({ count: s.count + 1 })),
    }),
    { name: 'counterStore' }
  )
);

This wraps setState internally, so it captures what was passed and how long it took. Works with middleware chaining (persist, immer, etc.):

import { persist } from 'zustand/middleware';

const useAuthStore = create(
  buoyDevTools(
    persist(
      (set) => ({ user: null, login: (u) => set({ user: u }) }),
      { name: 'auth-storage' }
    ),
    { name: 'authStore' }
  )
);

Features

  • Live state change capture — every state update is recorded with prev/next state
  • State inspection — full JSON viewer for state after each change
  • State diffing — tree view and split view comparing previous vs. next state
  • Changed keys tracking — see exactly which top-level keys changed per update
  • Store color coding — each store gets a consistent color for easy visual tracking
  • Performance monitoring — updates slower than 16ms are flagged (middleware mode)
  • Persist awareness — auto-detects stores using Zustand's persist middleware
  • Search & filter — search by store name or changed keys, filter to only state-changing updates
  • Jump to state — restore any store to a previously captured state
  • Reset store — reset any store to its initial state
  • Copy to clipboard — copy state data (Pro)

Comparison

| | watchStores() | buoyDevTools() middleware | |---|---|---| | Setup | One line, no store changes | Wrap each store's create() | | Risk | Zero — uses subscribe only | Low — wraps setState | | Captures partial | No | Yes | | Captures timing | No | Yes | | State diff | Yes | Yes | | Changed keys | Yes | Yes | | Persist detection | Yes | Yes |

Exports

// Primary — non-intrusive
import { watchStores } from '@buoy-gg/zustand';

// Advanced — middleware
import { buoyDevTools } from '@buoy-gg/zustand';

// Preset
import { zustandToolPreset, createZustandTool } from '@buoy-gg/zustand';

// Hook
import { useZustandStateChanges } from '@buoy-gg/zustand';

// Components (for custom UIs)
import {
  ZustandModal,
  ZustandStateChangeItem,
  ZustandStateDetailContent,
  ZustandIcon,
} from '@buoy-gg/zustand';

// Types
import type {
  ZustandStateChange,
  ZustandStoreInfo,
  ZustandFilter,
  StateChangeCategory,
} from '@buoy-gg/zustand';