Skip to content

API Reference

Browse the API documentation by package:

@outilx/core

Core utility functions that work in any JavaScript runtime (Node.js, Deno, Bun, browsers).

Array Utilities

Functions for array manipulation and transformation.

Cache

Caching utilities with TTL support and memoization.

JSON

Safe JSON parsing and stringification utilities.

URL

URL parameter parsing and manipulation.

Config

Configuration mapping utilities.

Async

Async processing with caching and execution strategies.

Similarity

Text similarity calculation (Levenshtein, TF-IDF).


@outilx/browser

Browser-specific utility functions. Re-exports all of @outilx/core plus:

Network

Network and HTTP utilities using browser APIs.

Storage

LocalStorage-based caching.


@outilx/node

Utility functions for Node.js environments.

File Operations

File manipulation and reading utilities.

Directory

Directory management and cleanup utilities.

Repository

Git repository automation utilities.


@outilx/react-hooks

A comprehensive React Hooks library for state management, storage, performance optimization, and async operations.

State Management

Hooks for managing different types of state (boolean, toggle, counter, map, array, number, custom methods).

Storage

Hooks for syncing state with storage mechanisms (localStorage, sessionStorage, cookies, URL).

Performance

Hooks for optimizing React components (memoization, latest value reference).

Lifecycle

Hooks for handling component lifecycle events.

Async

Hooks for handling asynchronous operations (cancelable tasks, pending state tracking).

Utilities

Utility functions for creating custom hooks.


@outilx/ai

AI utilities for code detection and streaming simulation.

Code Detection

Detect and parse code blocks from markdown-formatted text with automatic language identification.

Streaming Simulation

React hook for simulating streaming data, perfect for testing AI chat interfaces and demos.