Type Utilities for TypeScript
Types Included
nhb-toolbox
includes not only functional utilities but also a growing collection of type-level utilities designed to enhance type safety and developer ergonomics. These types are available through package subpaths: nhb-toolbox/[some-path]/types
.
Import
All types can be imported using this pattern:
import type { SomeType } from 'nhb-toolbox/types';
// Or
import type { SomeType } from 'nhb-toolbox/some-path/types';
1. Utility Types
Type helpers for advanced type manipulation and new type creation:
- Type transformations
- Conditional types
- Create new types
2. Common Types
Ready-to-use types for common patterns:
- Well-named, reusable aliases for primitive
- Date/time and other types for quick use
Constants
Along with type definitions, nhb-toolbox
exports a collection of ready-to-use constants for common development needs. These constants are available through package subpath: nhb-toolbox/constants
.
Import
All (20+) constants can be imported using this pattern:
import { CONSTANT_NAME } from 'nhb-toolbox/constants';