@parentspath/shared-components

v0.1.0

Published

Shared React components and utilities for the parents-apps ecosystem (solids-buddy, parents-path, daily-cherish)

Downloads

90

Readme

@parentspath/shared-components

Shared React components and utilities for the parents-apps ecosystem.

Installation

npm install @parentspath/shared-components
# or
yarn add @parentspath/shared-components
# or
bun add @parentspath/shared-components

Usage

import { LanguageSwitcher } from '@parentspath/shared-components/ui';
import { cn } from '@parentspath/shared-components/lib/cn';
import { useLocalStorage } from '@parentspath/shared-components/hooks';

Components

UI Components

  • LanguageSwitcher - Language selection component
  • AgeBadge - Display baby age
  • AllergenBadge - Display allergen severity

Utilities

  • cn() - Class name merger with clsx + tailwind-merge
  • formatDate() - Date formatting utilities

Hooks

  • useLocalStorage() - Local storage persistence
  • useDebounce() - Debounced values

Peer Dependencies

  • react ^18.0.0
  • react-dom ^18.0.0
  • tailwindcss ^3.4.0

License

MIT