Skip to main content

Overview

Returns a function that follows a target user. The current user must be authenticated. Use useFollowManager if you need status tracking and toggle behavior; use this hook directly when you need fine-grained control.

Usage Example

Parameters

The hook returns a function. That function accepts:
userId
string
required
The ID of the user to follow.

Returns

The function returns Promise<void>.