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

create-snap-react-app

v1.0.4

Published

CLI tool to scaffold SnapReact projects

Readme

SnapReact Documentation

Overview

SnapReact is a feature-rich React package designed to simplify the integration of common UI components such as SnackBars, Alerts, Confirm Dialogs, and Custom Modals. It also comes with pre-configured solutions for state management, theming, and routing. With the added flexibility of templates in both JavaScript (js-mui) and TypeScript (ts-mui), SnapReact is an ideal choice for rapid React app development. It’s powered by the Vite engine to offer fast and efficient development.

Installation

You can get started with SnapReact using npx or yarn.

Using npx (no installation required):

To scaffold a new SnapReact project without global installation, simply run:

npx create-snap-react-app my-app

This command will create a new project named my-app using the latest version of SnapReact.

Using yarn (global installation):

Alternatively, you can install the CLI tool globally using Yarn:

yarn global add create-snap-react-app

Once installed, create a new SnapReact project by running:

create-snap-react-app my-app

This will set up your new SnapReact project in the my-app folder.


Core Features Usage

1. SnackBar

The SnackBar displays floating messages at the bottom of the screen, perfect for notifications like success, error, or information.

Usage:
import { snap_features } from 'snap-features';

const { setSnackBar } = snap_features();

// Open SnackBar with Undo functionality
setSnackBar(true, "Snack message", () => setAlert("Undo action", "info"));

// Open SnackBar without undo
setSnackBar(true, "Snack message");

2. Alert

Alerts notify users about important events. You can customize the severity (success, error, info) based on your needs.

Usage:
import { snap_features } from 'snap-features';

const { setAlert } = snap_features();

// Show a success alert
setAlert("Success message", "success");

3. Confirm Dialog

The Confirm Dialog asks users to confirm actions (e.g., delete items). You can set custom buttons with handlers for each decision.

Usage:
import { snap_features } from 'snap-features';

const { setConfirm } = snap_features();

// Show confirm dialog with Yes/No buttons
setConfirm(true, "Confirmation title", "Are you sure?", [
  { label: 'Yes', handler: () => setAlert("Confirmed", "success") },
  { label: 'No', handler: () => setAlert("Cancelled", "error") },
]);

4. Custom Modal

Custom modals can display interactive components, like forms, within your application.

Usage:
import { snap_features } from 'snap-features';

const { setNewConfirm } = snap_features();

// Open custom modal with your custom component
setNewConfirm(true, <YourCustomComponent />);

Pre-configured Integrations

  • Redux: Redux is pre-configured and ready for use. You can access the store and dispatch actions as needed.
  • Theme: Material UI (MUI) is set up with a default theme, customizable to suit your needs.
  • Routing: React Router is already integrated for easy navigation handling.

Templates

SnapReact includes two templates for your convenience:

  • js-mui template: A JavaScript-based template using Material UI.
  • ts-mui template: A TypeScript-based template using Material UI.

Simply choose the template based on your project needs when starting your app.


What You Get

JavaScript with MUI (pre-configured)

image

Typescript with MUI (pre-configured)

image


Conclusion

SnapReact offers a streamlined solution for integrating essential UI features like SnackBars, Alerts, Confirm Dialogs, and Custom Modals into your React application. With pre-configured Redux, MUI themes, and React Router, SnapReact helps you save time and focus on building your app. Whether you're using the js-mui or ts-mui template, SnapReact is designed to support your React development needs from start to finish.


This update includes the new npx and yarn commands for installing the SnapReact CLI tool, ensuring users can easily scaffold new projects using the SnapReact templates.