
Security News
CVE Volume Surges Past 48,000 in 2025 as WordPress Plugin Ecosystem Drives Growth
CVE disclosures hit a record 48,185 in 2025, driven largely by vulnerabilities in third-party WordPress plugins.
@tanstack/ai-svelte
Advanced tools
Svelte bindings for TanStack AI.
npm install @tanstack/ai-svelte
# or
pnpm add @tanstack/ai-svelte
# or
yarn add @tanstack/ai-svelte
<script>
import { createChat, fetchServerSentEvents } from '@tanstack/ai-svelte'
const chat = createChat({
connection: fetchServerSentEvents('/api/chat'),
})
</script>
<div>
{#each chat.messages as message}
<div>{message.role}: {message.parts[0].content}</div>
{/each}
{#if chat.isLoading}
<button onclick={chat.stop}>Stop</button>
{/if}
<button onclick={() => chat.sendMessage('Hello!')}> Send </button>
</div>
createChat(options)Creates a reactive chat instance. Returns an object with reactive getters and methods:
Reactive Properties (no $ prefix needed):
messages - Array of messages in the conversationisLoading - Boolean indicating if a response is being generatederror - Current error, if anyMethods:
sendMessage(content) - Send a messageappend(message) - Append a messagereload() - Reload the last assistant messagestop() - Stop the current response generationclear() - Clear all messagessetMessages(messages) - Set messages manuallyaddToolResult(result) - Add a tool resultaddToolApprovalResponse(response) - Respond to a tool approval requestThis library uses Svelte 5 runes ($state) internally, providing a clean API where you don't need to use the $ prefix to access reactive state:
<script>
const chat = createChat({ ... })
// No $ needed - these are reactive getters!
console.log(chat.messages)
console.log(chat.isLoading)
</script>
<!-- Reactivity works automatically in templates -->
{#each chat.messages as message}
...
{/each}
MIT
FAQs
Svelte bindings for TanStack AI
We found that @tanstack/ai-svelte demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 4 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
CVE disclosures hit a record 48,185 in 2025, driven largely by vulnerabilities in third-party WordPress plugins.

Security News
Socket CEO Feross Aboukhadijeh joins Insecure Agents to discuss CVE remediation and why supply chain attacks require a different security approach.

Security News
Tailwind Labs laid off 75% of its engineering team after revenue dropped 80%, as LLMs redirect traffic away from documentation where developers discover paid products.