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

bagon-hooks

v0.0.6

Published

A collection of zero-dependency hooks for SolidJS forked directly from Mantine Hooks.

Downloads

95

Readme

bagon-hooks

A collection of zero-dependency hooks for SolidJS forked directly from Mantine Hooks.

Quick start

Install it:

npm i bagon-hooks
# or
yarn add bagon-hooks
# or
pnpm add bagon-hooks
# or
bun add bagon-hooks

Use it:

import { useHotkeys } from 'bagon-hooks';

We want to achieve as 1:1 as possible with Mantine's original hooks. So you can always refer to their original docs. There are a few improvements and renaming because SolidJS has its own conventions. But just take note:

  1. We removed Solid's convention of use vs create as it's too confusing for familiarity with Mantine. So every hook in Bagon is prefixed with use.
  2. The only renaming we did was state -> signal.
  3. Refer to Mantine's original docs for deeper examples and usecases.
  4. Refer to Bagon Hooks's docs for actual SolidJS examples.

Features

  • 🌳 Tree-shakable
  • 🖌️ TypeScript support
  • 🔵 For SolidJS
  • 📦 Zero-dependencies (except Solid)

Roadmap

Hooks

Based on the @mantine/hooks library.

  • [x] ~~use-callback-ref~~ (Not needed, only used internally by mantine for preventing re-renders on a function)
  • [x] use-click-outside
  • [x] use-clipboard
  • [x] use-color-scheme
  • [x] use-counter
  • [x] use-debounced-callback
  • [x] ~~use-debounced-state~~ use-debounced-signal
  • [x] use-debounced-value
  • [x] use-did-update
  • [x] use-disclosure (✨ Improved, slightly better than mantine thanks to set for passing to stuff like onOpenChange)
  • [x] use-document-title
  • [x] use-document-visibility
  • [ ] use-event-listener
  • [x] use-eye-dropper (✨ improved, state management is inside the hook)
  • [x] use-favicon (✨ improved, more flexible, better control)
  • [ ] use-fetch
  • [ ] use-focus-return
  • [ ] use-focus-trap
  • [ ] use-focus-within
  • [ ] use-force-update
  • [x] use-fullscreen
  • [x] use-hash
  • [ ] use-headroom
  • [x] use-hotkeys
  • [x] use-hover
  • [x] use-id (Added, but note that there is createUniqueId in Solid)
  • [x] use-idle (Added, but note that there is createIdleTimer the official solid-primitives as well)
  • [x] use-in-viewport
  • [x] use-input-state
  • [x] use-intersection (Added, but note that there is createIntersectionObserver in the official solid-primitives as well)
  • [x] use-interval
  • [x] ~~use-is-first-render~~ (Every component function in SolidJS runs only once! Every component is first render only 🙂)
  • [x] ~~use-isomorphic-effect~~ (Solid's createEffect is technically already isomorphic because it doesn't error on SSR. Also, it also only runs on client-side.)
  • [ ] use-list-state
  • [x] use-local-storage
  • [x] use-local-storage-store (✨ Improved, more similar to 'createStore' API).
  • [ ] use-logger
  • [ ] use-map
  • [x] use-media-query
  • [ ] use-merged-ref
  • [x] use-mounted
  • [x] use-mouse
  • [x] use-move
  • [ ] use-mutation-observer
  • [x] use-network
  • [x] use-orientation
  • [x] use-os
  • [ ] use-page-leave
  • [ ] use-pagination
  • [ ] use-previous
  • [ ] use-queue
  • [ ] use-reduced-motion
  • [x] use-resize-observer
  • [ ] use-scroll-into-view
  • [ ] use-session-storage
  • [ ] use-set-state
  • [ ] use-set
  • [ ] use-shallow-effect
  • [ ] use-state-history
  • [ ] use-text-selection
  • [ ] use-throttled-callback
  • [ ] use-throttled-state
  • [ ] use-throttled-value
  • [x] use-timeout
  • [x] use-toggle
  • [x] use-uncontrolled
  • [ ] use-validated-state
  • [ ] use-viewport-size
  • [ ] use-window-event
  • [ ] use-window-scroll
  • [ ] utils

New in Bagon Hooks

  • [x] use-keyboard (✨ Runs even on single keys as opposed useHotkeys that only runs on combinations, so more general usecases)
  • [x] use-disclosure-data (✨ Improved, an alternative to use-disclosure for data-driven disclosures. I use it)

Others

  • [x] Docs Website (Powered by mdx + tailwind prose)
  • [x] Examples
  • [ ] Tests?

Contributing

This library is far from done. If you have time implementing the roadmap, feel free to submit a pull request. We always appreciate collaborators. If you find anything outdated, please make an issue. If you like this project, consider giving it a star! ⭐️

License

This project is licensed under the MIT License

Credits

  • Mantine Hooks - amazing library for components and hooks, but currently not in SolidJS so we forked that part only.