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

@khalidabdi/boxcn

v1.0.26

Published

A smart CLI to install and import Shadcn/UI components into React, Vite, or Next.js projects easily.

Readme

📦 Boxcn CLI — Smart Shadcn/UI Component Installer for React, Vite & Next.js

NPM Version NPM Downloads GitHub Stars

Boxcn CLI Example

Boxcn CLI is a smart and developer-friendly command-line tool that helps you easily install and import Shadcn/UI components into your React, Vite, or Next.js projects.

With one simple command, Boxcn automatically:

  • Installs your selected Shadcn component
  • Adds the correct import statements into your React file
  • Saves you time, effort, and endless manual setup ✨

🚀 Features

  • Fast & Simple — Install Shadcn components in seconds.
  • 🧩 Smart Imports — Automatically injects imports into your React files.
  • 🎨 Interactive CLI — Clean, user-friendly terminal experience.
  • 🔧 Fully Compatible — Works with Vite, Next.js, and CRA projects.
  • 🪄 Automation Ready — Great for large-scale projects and UI consistency.

🛠️ Installation

Before using Boxcn, make sure you have Shadcn/UI installed in your project.

🌍 Global Installation

npm install -g @khalidabdi/boxcn

📦 Local Installation

npm install @khalidabdi/boxcn

💡 Usage 🔍 Search for Components


Boxcn search

This opens an interactive CLI that allows you to select any Shadcn/UI component. Boxcn will then:

Find and install the selected component using npx shadcn@latest add

Automatically add the correct import statement to your target React file

No need to browse documentation — everything happens in seconds ⚡

✨ New Command — Boxcn edit You can now automatically insert a selected Shadcn/UI component directly inside your React file.

Add this marker where you want to insert the component:


{/**after*/}

Then run:


Boxcn edit

Boxcn will:

Prompt you to choose a Shadcn component (e.g., Button, Card, Accordion).

Locate {/*after/} inside your file.

Automatically insert the JSX for the component below that line.

🪄 Example Before:


export default function App() {
  return (
    <div>
      <h1>Hello</h1>
      {/**after*/}
    </div>
  )
}

After running:

Boxcn edit

Select: Button

Result:


export default function App() {
  return (
    <div>
      <h1>Hello</h1>
      <Button>Click me</Button>
    </div>
  )
}

💡 Notes:

The Boxcn edit command only works if {/*after/} exists in your file.

Each added component is automatically imported and positioned correctly.

Default target file: ./src/App.tsx

Works perfectly with React, Vite, or Next.js projects.

🚀 Why It’s Awesome Boxcn edit transforms Boxcn CLI from a simple installer into a powerful UI automation assistant. It saves time, automates repetitive edits, and keeps your code organized.

Example Flow:

Boxcn edit

✅ Choose a Shadcn component ✅ Boxcn finds {/*after/} ✅ Component is inserted instantly!

📸 Example Screenshot

🤝 Contributing Contributions, pull requests, and feedback are welcome 💡 Help make Boxcn even better for the React developer community!

👉 Open an issue 👉 Submit a pull request

📜 License Licensed under the MIT License © Khalid Abdi

🌟 Why Developers Love Boxcn Boxcn CLI helps developers save time and automate repetitive setup tasks when working with Shadcn/UI components. With a single command, you can integrate and import beautiful UI elements seamlessly into your React project.

🔍 SEO Keywords (for better discoverability) shadcn ui, boxcn cli, react components, vite, nextjs, ui automation, frontend tools, component installer, shadcn cli, react shadcn, developer productivity, typescript, shadcn generator, ui builder

👨‍💻 Author Created with ❤️ by Khalid Abdi Follow for more developer tools and open-source projects 🚀

📦 NPM Package ⭐ GitHub Repository