Skip to main content
The @gatelit/sdk-vue package provides a single composable — useGatelit — that wraps the Gatelit JS SDK with Vue 3 reactivity. Streaming, abort control, and error state are handled automatically; you only need to bind the returned refs in your template.

Prerequisites

  • Vue 3.5 or later
  • @gatelit/sdk (peer dependency — installed alongside the Vue SDK)

Install

Quick start

The example below shows a minimal chat interface. useGatelit connects to your gateway, and the returned messages, isStreaming, and error refs update reactively as each chunk arrives.
You do not need to manage streaming state, an AbortController, or error cleanup yourself. useGatelit handles all of these internally. The assistant message’s content grows in real time as each chunk arrives.

Next steps

See the useGatelit reference for the full API — all returned refs, function signatures, and advanced usage patterns including Nuxt.