Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ Perfect consistency, always.

## Everything is Programmable

SpacetimeDB doesn't limit you to declarative rules or configuration files. Your module is real code (Rust, C#, or TypeScript) running inside the database. You have the full power of a procedural, normal programming language at your disposal.
SpacetimeDB doesn't limit you to declarative rules or configuration files. Your module is real code (Rust, C#, TypeScript, or C++) running inside the database. You have the full power of a procedural, normal programming language at your disposal.

Need custom authorization logic? Write a function. Need to validate complex business rules? Write a function. Need to transform data before storing it? Write a function.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,12 @@ slug: /intro/language-support

## Server Database Modules

SpacetimeDB modules define your database schema and server-side business logic. Modules can be written in three languages:
SpacetimeDB modules define your database schema and server-side business logic. Modules can be written in four languages:

- **[Rust](../../00200-core-concepts/00100-databases.md)** - High performance, compiled to WebAssembly [(Quickstart)](../00200-quickstarts/00500-rust.md)
- **[C#](../../00200-core-concepts/00100-databases.md)** - Great for Unity developers, compiled to WebAssembly [(Quickstart)](../00200-quickstarts/00600-c-sharp.md)
- **[TypeScript](../../00200-core-concepts/00100-databases.md)** - Ideal for web developers, runs on V8 [(Quickstart)](../00200-quickstarts/00400-typescript.md)
- **[C++](../../00200-core-concepts/00100-databases.md)** - Great for Unreal Engine developers and C++ teams, compiled to WebAssembly [(Quickstart)](../00200-quickstarts/00700-cpp.md)

## Client SDKs

Expand Down
4 changes: 2 additions & 2 deletions docs/docs/00100-intro/00100-getting-started/00500-faq.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ SpacetimeDB replaces the entire server. Your game state lives in tables, your ga

Firebase and Supabase are Backend-as-a-Service platforms. They give you a database with an API layer on top, but your application logic still runs elsewhere (cloud functions, edge functions, or your own server). Complex business logic is awkward to express as database triggers or serverless functions.

SpacetimeDB lets you write your entire application as a module in a real programming language (Rust, C#, TypeScript) that runs inside the database. You get full transactional guarantees, direct table access, and real-time subscriptions without the cold starts, execution limits, or awkward abstractions of serverless functions.
SpacetimeDB lets you write your entire application as a module in a real programming language (Rust, C#, TypeScript, or C++) that runs inside the database. You get full transactional guarantees, direct table access, and real-time subscriptions without the cold starts, execution limits, or awkward abstractions of serverless functions.

### How is SpacetimeDB different from a regular database (PostgreSQL, MySQL)?

Expand Down Expand Up @@ -149,7 +149,7 @@ SpacetimeDB 2.0 also includes a **type-safe query builder** for client-side subs

1. Install the CLI: `curl -sSf https://install.spacetimedb.com | sh`
2. Start a local instance: `spacetime start`
3. Create a project: `spacetime init --lang rust` (or `csharp`, `typescript`)
3. Create a project: `spacetime init --lang rust` (or `csharp`, `typescript`, `cpp`)
4. Write your module, publish it: `spacetime publish my-app`
5. Generate client bindings: `spacetime generate --lang typescript --out-dir src/module_bindings`
6. Connect from your client using the generated code
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { CppModuleVersionNotice } from "@site/src/components/CppModuleVersionNot
import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';

Quick reference for SpacetimeDB module syntax across Rust, C#, and TypeScript.
Quick reference for SpacetimeDB module syntax across Rust, C#, TypeScript, and C++.

## Project Setup

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ Consider a game inventory with ordered pockets. A `Vec<Item>` preserves pocket o

## Binary Data and Files

SpacetimeDB includes optimizations for storing binary data as `Vec<u8>` (Rust), `List<byte>` (C#), or `t.array(t.u8())` (TypeScript). You can store files, images, serialized data, or other binary blobs directly in table columns.
SpacetimeDB includes optimizations for storing binary data as `Vec<u8>` (Rust), `List<byte>` (C#), `t.array(t.u8())` (TypeScript), or `std::vector<uint8_t>` (C++). You can store files, images, serialized data, or other binary blobs directly in table columns.

This approach works well when:
- The binary data is associated with a specific row (e.g., a user's avatar image)
Expand Down
4 changes: 2 additions & 2 deletions docs/docs/00200-core-concepts/00600-clients.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,11 +83,11 @@ New to SpacetimeDB client development? Follow this progression:
1. **[Generate Client Bindings](./00600-clients/00200-codegen.md)** - Create type-safe interfaces from your module
2. **[Connect to SpacetimeDB](./00600-clients/00300-connection.md)** - Establish a connection and understand the lifecycle
3. **[Use the SDK API](./00600-clients/00400-sdk-api.md)** - Learn about subscriptions, reducers, and callbacks
4. **Language Reference** - Dive into language-specific details: [Rust](./00600-clients/00500-rust-reference.md), [C#](./00600-clients/00600-csharp-reference.md), [TypeScript](./00600-clients/00700-typescript-reference.md)
4. **Language Reference** - Dive into language-specific details: [Rust](./00600-clients/00500-rust-reference.md), [C#](./00600-clients/00600-csharp-reference.md), [TypeScript](./00600-clients/00700-typescript-reference.md), and [Unreal Engine](./00600-clients/00800-unreal-reference.md)

## Next Steps

- Follow a **Quickstart guide** [Rust](../00100-intro/00200-quickstarts/00500-rust.md), [C#](../00100-intro/00200-quickstarts/00600-c-sharp.md), or [TypeScript](../00100-intro/00200-quickstarts/00400-typescript.md) to build your first client
- To build your first client, follow a **Quickstart guide** for [Rust](../00100-intro/00200-quickstarts/00500-rust.md), [C#](../00100-intro/00200-quickstarts/00600-c-sharp.md), or [TypeScript](../00100-intro/00200-quickstarts/00400-typescript.md), or use the [Unreal tutorial](../00100-intro/00300-tutorials/00400-unreal-tutorial/index.md)
- Learn about [Databases](./00100-databases.md) to understand what you're connecting to
- Explore [Subscriptions](./00400-subscriptions.md) for efficient data synchronization
- Review [Reducers](./00200-functions/00300-reducers/00300-reducers.md) to understand server-side state changes
2 changes: 1 addition & 1 deletion docs/static/llms.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ A module is a collection of functions and schema definitions, which can be writt
- [The Database Module](/docs/databases): A module is a collection of functions and schema definitions, which can be written in TypeScript, C#, Rust, or C++. Modules define the structure of your database and the server-side logic that processes and handles client requests.
- [Automatic Migrations](/docs/databases/automatic-migrations): When you republish a module to an existing database using spacetime publish , SpacetimeDB attempts to automatically migrate your database schema to match the new module definition. This allows you to update your module code and redeploy without losing existing data, as long as the changes are compatible.
- [spacetime publish](/docs/databases/building-publishing): This guide covers how to build and publish your SpacetimeDB module.
- [Cheat Sheet](/docs/databases/cheat-sheet): Quick reference for SpacetimeDB module syntax across Rust, C#, and TypeScript.
- [Cheat Sheet](/docs/databases/cheat-sheet): Quick reference for SpacetimeDB module syntax across Rust, C#, TypeScript, and C++.
- [spacetime dev](/docs/databases/developing): This guide covers how to create a new SpacetimeDB database module project.
- [Incremental Migrations](/docs/databases/incremental-migrations): SpacetimeDB does not provide built-in support for general schema-modifying migrations. It does, however, allow adding new tables, and changing reducers' definitions in arbitrary ways. It's possible to run general migrations using an external tool, but this is tedious, necessitates downtime, and imposes the requirement that you update all your clients at the same time as publishing your new module version.
- [Transactions and Atomicity](/docs/databases/transactions-atomicity): SpacetimeDB provides strong transactional guarantees for all database operations. Every reducer runs inside a database transaction, ensuring your data remains consistent and reliable even under concurrent load.
Expand Down
Loading