useFetchCommentByForeignId
Overview
TheuseFetchCommentByForeignId hook allows you to retrieve a specific comment by its foreign ID. It optionally includes the parent comment, making it useful for displaying threaded comment structures or fetching detailed comment data.
Usage Example
Parameters & Returns
Parameters
The hook returns a function that accepts an object with the following fields:string
required
The foreign ID of the comment to fetch.
boolean
Whether to include the parent comment.
Returns
The function resolves with an object containing the comment and optionally its parent comment:Comment
The details of the fetched comment.
Comment \
null`

