Files
metabuilder/hooks/package.json
johndoe6345789 78a54228df feat(hooks): Create centralized hooks npm package
- Added @metabuilder/hooks workspace package at root
- Consolidated 30 React hooks from across codebase into single module
- Implemented conditional exports for tree-shaking support
- Added comprehensive package.json with build/lint/typecheck scripts
- Created README.md documenting hook categories and usage patterns
- Updated root package.json workspaces array to include hooks
- Supports multi-version peer dependencies (React 18/19, Redux 8/9)

Usage:
  import { useDashboardLogic } from '@metabuilder/hooks'
  import { useLoginLogic } from '@metabuilder/hooks/useLoginLogic'

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
2026-01-23 19:17:17 +00:00

63 lines
1.8 KiB
JSON

{
"name": "@metabuilder/hooks",
"version": "1.0.0",
"description": "Centralized collection of React hooks used across MetaBuilder",
"main": "index.ts",
"types": "index.d.ts",
"scripts": {
"build": "tsc --declaration --emitDeclarationOnly",
"lint": "eslint .",
"typecheck": "tsc --noEmit"
},
"keywords": [
"react",
"hooks",
"authentication",
"dashboard",
"storage",
"ui"
],
"author": "MetaBuilder",
"license": "MIT",
"peerDependencies": {
"react": "^18.0.0 || ^19.0.0",
"react-dom": "^18.0.0 || ^19.0.0",
"react-redux": "^8.0.0 || ^9.0.0"
},
"devDependencies": {
"@types/react": "^18.2.0 || ^19.0.0",
"typescript": "^5.0.0"
},
"files": [
"*.ts",
"*.tsx",
"index.d.ts",
"README.md"
],
"exports": {
".": {
"import": "./index.ts",
"types": "./index.d.ts"
},
"./useLoginLogic": "./useLoginLogic.ts",
"./useRegisterLogic": "./useRegisterLogic.ts",
"./usePasswordValidation": "./usePasswordValidation.ts",
"./useAuthForm": "./useAuthForm.ts",
"./useDashboardLogic": "./useDashboardLogic.ts",
"./useResponsiveSidebar": "./useResponsiveSidebar.ts",
"./useHeaderLogic": "./useHeaderLogic.ts",
"./useProjectSidebarLogic": "./useProjectSidebarLogic.ts",
"./useStorageDataHandlers": "./useStorageDataHandlers.ts",
"./useStorageSettingsHandlers": "./useStorageSettingsHandlers.ts",
"./useStorageSwitchHandlers": "./useStorageSwitchHandlers.ts",
"./useFaviconDesigner": "./useFaviconDesigner.ts",
"./useDragResize": "./useDragResize.ts",
"./useGithubBuildStatus": "./use-github-build-status.ts"
},
"repository": {
"type": "git",
"url": "https://github.com/metabuilder/metabuilder.git",
"directory": "hooks"
}
}