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 🙏

© 2025 – Pkg Stats / Ryan Hefner

create-flexium

v0.10.7

Published

Scaffold a Flexium project with one command

Downloads

7,262

Readme

create-flexium

Scaffold a new Flexium project with one command.

Usage

With npm 6+

npm create flexium@latest

With npm 7+

npm create flexium@latest my-app

With Yarn

yarn create flexium my-app

With pnpm

pnpm create flexium my-app

With Bun

bun create flexium my-app

What You Get

1. Vite + TypeScript (Recommended)

Production-ready setup with:

  • ⚡ Vite for instant hot module replacement
  • 🔷 TypeScript with strict mode
  • 📦 Automatic JSX runtime (no h imports needed)
  • 🎨 Example components
  • 🛠️ ESLint + Prettier configured
  • 🚀 Optimized build configuration

Perfect for: Production apps, learning TypeScript

npm create flexium@latest my-app
# Choose: Vite + TypeScript (1)
cd my-app
npm install
npm run dev

2. Vanilla (No Build)

Simple starter with zero build tools:

  • 📄 Single HTML file
  • 🎯 Works immediately in browser
  • 🔄 Live reload with any HTTP server
  • 💡 Great for learning

Perfect for: Quick experiments, learning basics, no-build projects

npm create flexium@latest my-app
# Choose: Vanilla (2)
cd my-app
npx serve .

3. Todo App (Reference)

Complete reference implementation:

  • ✅ Full todo application
  • 🎨 Best practices demonstrated
  • 📝 Comprehensive comments
  • 🔍 Real-world patterns

Perfect for: Learning patterns, reference implementation

npm create flexium@latest my-app
# Choose: Todo App (3)
cd my-app
npm install
npm run dev

4. SSR (Server-Side Rendering)

Server-side rendering for optimal performance:

  • 🚀 Express.js server with compression
  • 📊 Server-side rendering for better SEO
  • 💨 Client-side hydration
  • 🔥 Hot module replacement in development
  • 📦 Optimized production builds

Perfect for: SEO-critical apps, content-heavy sites, optimal performance

npm create flexium@latest my-app
# Choose: SSR (4)
cd my-app
npm install
npm run dev

5. PWA (Progressive Web App)

Full PWA with modern features:

  • 📱 Install to home screen
  • 🔌 Offline support with service worker
  • 🔔 Push notifications
  • 🔄 Background sync
  • 📦 App manifest and icons
  • 💾 LocalStorage persistence

Perfect for: Mobile-first apps, offline-capable apps, installable web apps

npm create flexium@latest my-app
# Choose: PWA (5)
cd my-app
npm install
npm run dev

6. Monorepo (pnpm workspaces)

Monorepo structure with shared packages:

  • 📦 pnpm workspaces for efficient package management
  • 🧩 Shared component library (@monorepo/components)
  • 🛠️ Shared utility library (@monorepo/utils)
  • 🔗 Cross-package imports with workspace protocol
  • 🎯 Unified build, lint, and format scripts
  • 🔥 Hot module replacement across packages

Perfect for: Large projects, multiple apps, shared component libraries

npm create flexium@latest my-app
# Choose: Monorepo (6)
cd my-app
pnpm install  # requires pnpm
pnpm dev

Features

  • 🎯 Interactive CLI - Choose your template with a beautiful interface
  • 📦 Zero Dependencies - Pure Node.js, no external packages
  • Instant Setup - Get started in seconds
  • 🎨 6 Templates - Pick the right starter for your needs
  • 🔷 TypeScript Ready - Full TypeScript support out of the box
  • 🚀 Production Ready - Optimized for deployment
  • Input Validation - Prevents invalid project names
  • 📱 PWA Support - Build installable progressive web apps
  • 🔄 SSR Support - Server-side rendering for optimal performance
  • 📦 Monorepo Support - Multi-package workspace setup

Requirements

  • Node.js 18.0.0 or higher
  • pnpm 8.0.0 or higher (for monorepo template only)

Input Validation

The CLI validates project names to ensure they follow npm package naming conventions:

  • ✅ Only lowercase letters, numbers, hyphens, and underscores
  • ✅ Maximum 214 characters
  • ✅ Cannot start with a dot or underscore
  • ✅ No reserved names (node_modules, favicon.ico)

Valid examples:

my-app
my-project-name
my_awesome_app
app-v2

Invalid examples:

MyApp           # uppercase letters not allowed
my app          # spaces not allowed
.myapp          # cannot start with dot
node_modules    # reserved name

Template Comparison

| Feature | Vite | Vanilla | Todo | SSR | PWA | Monorepo | |---------|------|---------|------|-----|-----|----------| | TypeScript | ✅ | ❌ | ❌ | ❌ | ✅ | ✅ | | Build Tool | Vite | None | Vite | Vite | Vite | Vite | | Hot Reload | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | | Production Build | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | | SSR | ❌ | ❌ | ❌ | ✅ | ❌ | ❌ | | Offline Support | ❌ | ❌ | ❌ | ❌ | ✅ | ❌ | | Multi-Package | ❌ | ❌ | ❌ | ❌ | ❌ | ✅ | | Complexity | Low | Minimal | Medium | High | Medium | High |

Learn More

License

MIT