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

ghost-ui-native

v0.1.7

Published

Ghost UI — React Native components with NativeWind, theming, and a source-install CLI.

Readme

ghost-ui-native

React Native UI components with NativeWind and light/dark theming.

Links

| | | |---|---| | Website | ghost-ui.kashif-dev.site | | GitHub | github.com/codewithkashi/ghost-ui-native | | npm | ghost-ui-native |

Install

npm install ghost-ui-native
npx ghost-ui-native init --yes

init --yes installs ghost-ui-native plus NativeWind runtime deps, and writes Metro / Babel / nativewind-env.d.ts for NativeWind + @/ aliases. Without --yes, it prints the suggested install commands.

On Expo, prefer npx expo install for native modules (react-native-reanimated, react-native-safe-area-context, react-native-svg, react-native-worklets). The CLI detects Expo and writes Expo-compatible Babel/Metro configs.

After Metro or Babel changes:

npx react-native start --reset-cache
# or: npx expo start --clear

Setup

Import ./global.css once at your app entry and wrap the root:

import './global.css';
import { SafeAreaProvider } from 'react-native-safe-area-context';
import { GhostUIProvider } from 'ghost-ui-native';

export default function App() {
  return (
    <SafeAreaProvider>
      <GhostUIProvider defaultTheme="system">
        <YourApp />
      </GhostUIProvider>
    </SafeAreaProvider>
  );
}

Required checklist (RN CLI + NativeWind)

| Step | Action | |------|--------| | 1 | Install NativeWind, Tailwind 3.4, and peers | | 2 | global.css + tailwind.config.js (nativewind/preset) | | 3 | Metro: withNativeWind(config, { input: './global.css' }) | | 4 | Babel: nativewind/babel | | 5 | import './global.css' in the app entry | | 6 | nativewind-env.d.ts with declare module '*.css' {} (TS 6+) | | 7 | tsconfig paths "@/*": ["./*"] (IDE only) | | 8 | Babel module-resolver "@": "./" (Metro needs this) | | 9 | Restart Metro with --reset-cache |

Full explanations: SETUP.md.

Ghost theme (default)

ghost-ui-native init writes a violet-forward theme into global.css — not the default shadcn zinc palette. Tokens include --primary: 262 83% 58%, tinted borders/accents, and --radius: 0.75rem. Components use rounder corners (rounded-xl / rounded-2xl), light shadows, and press feedback on primary actions.

To customize, edit CSS variables in global.css or replace the file after init. Re-run Metro with --reset-cache after token changes.

Troubleshooting

  • TS: side-effect import of ./global.css — add declare module '*.css' {} in nativewind-env.d.ts (not nativewind.d.ts) and include that file in tsconfig.
  • Metro: unable to resolve ./global.css — wrap Metro with withNativeWind and add the nativewind/babel preset.
  • Metro: unable to resolve @/lib/utils — tsconfig paths are not enough; configure babel-plugin-module-resolver with "@": "./" and --reset-cache.

Usage

import {
  Button,
  Card,
  CardHeader,
  CardTitle,
  Text,
  useGhostTheme,
} from 'ghost-ui-native';

function Example() {
  const { toggleTheme, resolvedTheme } = useGhostTheme();

  return (
    <Card className="m-4">
      <CardHeader>
        <CardTitle>Ghost UI</CardTitle>
      </CardHeader>
      <Text className="mb-3 text-muted-foreground">{resolvedTheme}</Text>
      <Button onPress={toggleTheme}>Toggle theme</Button>
    </Card>
  );
}

Use semantic classes: bg-background, text-foreground, bg-primary, text-primary-foreground, border-border.

Theme modes: system | light | dark.

Add components (source copy)

npx ghost-ui-native add button card dialog
npx ghost-ui-native add --all --yes

| Command | Description | |---------|-------------| | init | Configure the project | | add | Copy components into the project | | list | List components | | search | Search components | | view | View component metadata | | diff | Diff local files vs registry | | doctor | Check project setup |

Flags: --yes --overwrite --dry-run --diff --all

Components

Text Button Badge Separator Card Skeleton Avatar Progress AspectRatio Input Textarea Label Checkbox Switch RadioGroup Slider Toggle Accordion Collapsible Tabs Dialog AlertDialog Select Sheet Alert Toast Empty Breadcrumb Pagination Popover Tooltip DropdownMenu Drawer InputOTP Table Carousel Spinner Bubble Marker Message MessageScroller Calendar GhostUIProvider

Links

  • Documentation: https://ghost-ui.kashif-dev.site
  • GitHub: https://github.com/codewithkashi/ghost-ui-native
  • npm: https://www.npmjs.com/package/ghost-ui-native

License

MIT