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

nexus-shell

v0.1.2

Published

Nexus-Shell is a professional-grade, library-first frontend framework for building "Workbench" style applications (like VS Code or JupyterLab). Built with **React 19**, **TypeScript**, and **FlexLayout**, it provides a modular foundation for complex, mult

Readme

Nexus-Shell Framework

Nexus-Shell is a professional-grade, library-first frontend framework for building "Workbench" style applications (like VS Code or JupyterLab). Built with React 19, TypeScript, and FlexLayout, it provides a modular foundation for complex, multi-panel web tools.

✨ Key Features

  • Advanced Tab Docking: Complete drag-and-drop window management with splits, tabs, and sidebars.
  • Modular Registry System: Decouple commands, menus, and plugins from the core UI.
  • Persistence: Automatic workspace restoration via localStorage.
  • Command Palette: Ctrl+Shift+P searchable command interface.
  • Theming: First-class support for Light, Dark, and custom themes (includes a Georgia Tech theme), optimized for high accessibility and reduced eye strain.
  • Accessible Components: Input fields and buttons follow strict UI/UX guidelines for contrast, sizing, and focus states.
  • Library Ready: ESM and UMD bundles with full TypeScript type definitions.

🚦 Quick Start

1. Installation

npm install nexus-shell

2. Basic Setup

In your main entry point (e.g., App.tsx):

import { ShellLayout, initializeShell } from 'nexus-shell';
import 'nexus-shell/style.css';

// Initialize core shell services
initializeShell();

export default function App() {
  return (
    <div className="h-screen w-screen">
      <ShellLayout />
    </div>
  );
}

🏗 Core Concepts

1. Registries (The Brains)

Nexus-Shell uses registries to manage global state without component coupling.

  • commandRegistry: Register global actions with IDs, labels, and optional keybindings.
  • menuRegistry: Map commands to the top Menu Bar.
  • pluginRegistry: Manage the lifecycle (activate/deactivate) of modular features.

2. Commands & Menus

import { commandRegistry, menuRegistry } from 'nexus-shell';

// Register a command
commandRegistry.registerCommand({
  id: 'my-app.hello',
  label: 'Say Hello',
  keybinding: 'Control+L',
  execute: () => alert('Hello World!'),
});

// Add it to the Help menu
menuRegistry.registerMenu('Help', {
  id: 'help.hello',
  label: 'Say Hello',
  commandId: 'my-app.hello',
});

3. Layout Management

The layout is powered by flexlayout-react. You can dynamically add tabs from anywhere in your app:

import { useLayoutStore } from 'nexus-shell';

const addMyTab = () => {
  useLayoutStore.getState().addTab('my-component', 'My Tab Title');
};

🛠 Step-by-Step: Creating a Custom Application

Follow these steps to build a feature-rich application using Nexus-Shell:

Step 1: Initialize the Shell

Call initializeShell() before your app renders. This sets up the default "Welcome" tab, core menus, and global keyboard listeners.

Step 2: Define your Components

Create React components that you want to appear as tabs. You must register these in the factory of the ShellLayout or provide a custom factory.

Step 3: Register Commands and Menus

Define the actions your users can take. By using commandRegistry, your actions automatically show up in the Command Palette (Ctrl+Shift+P) and can be triggered by Keyboard Shortcuts.

Step 4: Implement Plugins

For larger apps, encapsulate features into Plugins:

import { IPlugin, commandRegistry } from 'nexus-shell';

export const MyFeaturePlugin: IPlugin = {
  id: 'my-feature',
  name: 'My Feature',
  activate: () => {
    // Register commands, menus, and sidebars here
  },
  deactivate: () => {
    // Cleanup
  }
};

Step 5: Choose a Theme

Users can switch themes in the Settings sidebar. You can also set the theme programmatically:

import { useThemeStore } from 'nexus-shell';

useThemeStore.getState().setTheme('gt'); // Go Jackets!

🎨 Customization API

Nexus-Shell is highly configurable via props on the ShellLayout component. This allows you to repurpose the workbench for different application needs.

1. Menu Bar Configuration (menuConfig)

Define hierarchical menus with nested submenus and commands.

const myMenus = {
  'File': [
    { id: 'new', label: 'New File', commandId: 'nexus.new-tab' },
    { id: 'recent', label: 'Open Recent', submenu: [
      { id: 'r1', label: 'Project Alpha' },
      { id: 'r2', label: 'Project Beta' }
    ]}
  ]
};

2. Status Bar Widgets (statusBarConfig)

Add info widgets to the bottom bar with specific alignments.

const myStatusBar = [
  { id: 'info', label: 'System OK', alignment: 'left', icon: Activity },
  { id: 'v', label: 'v1.0.0', alignment: 'center' },
  { id: 'user', label: 'Admin', alignment: 'right', onClick: () => alert('Admin Clicked') }
];

3. Sidebar Panels (panels)

Inject custom tools into the left Activity Bar.

const myPanels = [
  { id: 'home', label: 'Home', icon: Home, component: MyHomeComponent },
  { id: 'db', label: 'Database', icon: Database, component: <DbExplorer /> }
];

4. Chat Slash Commands (slashCommands)

Extend the chat interface with custom functional commands.

const myChatCommands = [
  { command: 'ping', description: 'Test latency', execute: () => console.log('Pong!') },
  { command: 'clear', description: 'Reset chat', execute: (args) => resetLogic() }
];

5. Search Integration (SearchWidget)

A reusable component for implementing project-wide search.

<SearchWidget 
  placeholder="Filter objects..."
  onSearch={(query) => doFilter(query)}
  results={filteredResults}
  suggestions={['recent-1.txt', 'recent-2.txt']}
  onSelect={(result) => openItem(result)}
  loading={isSearching}
/>

Usage Example:

<ShellLayout 
  menuConfig={myMenus}
  statusBarConfig={myStatusBar}
  panels={myPanels}
  slashCommands={myChatCommands}
/>

📂 Project Structure (Library)

/dist               <-- Compiled library artifacts (ESM, UMD, CSS, Types)
/src
  /components       <-- UI Components (Layout, Widgets)
  /core
    /registry       <-- Registry logic (Commands, Menus, Plugins)
    /services       <-- State Management (Zustand)
  /index.ts         <-- Public API Entry Point

🧪 Development & Testing

  • Run Dev App: npm run dev
  • Build Library: npm run build
  • Run Tests: npx playwright test

📄 License

MIT © [David/TechMuch]