Skip to content

UseTokenCountReturn

Defined in: react-hooks/src/use-token-count.ts:28

Token count return value.

characterCount: number

Defined in: react-hooks/src/use-token-count.ts:32

Characters count


countTokens: (text) => number

Defined in: react-hooks/src/use-token-count.ts:38

Count tokens for text

string

number


isEstimating: boolean

Defined in: react-hooks/src/use-token-count.ts:36

Whether estimation is in progress


tokenCount: number

Defined in: react-hooks/src/use-token-count.ts:30

Estimated token count


wordCount: number

Defined in: react-hooks/src/use-token-count.ts:34

Word count