This is the documentation of version 0.47.0. Go to the latest version, 1.0.0-rc.5.
TomTom Maps for JavaScript
    Preparing search index...

    Function extractLastUserText

    • Extracts the text content of the last user message in a message array. Returns null if no user message is found or if content has no text.

      Parameters

      • messages: readonly ModelMessage[]

      Returns string | null