# Posts

> Forum threads and feedback posts on boards. Replies are comments on the messaging core, votes are reactions, and each post is a moderation item members can report. Feedback posts move through a status from open to done.

- Category: Collaboration
- Module: `posts`
- Modes: `managed`, `custom`
- Docs: https://bettersupabase.com/docs/blocks/posts
- Page: https://bettersupabase.com/blocks/posts

## Install

```bash
npx better-supabase add posts
```

The command also installs `updated-at`, `tenant`, `access`, `comments`, `subjects`, `reactions`, `moderation`, `messaging`.

## Configure

Add the block to `better-supabase.config.ts`:

```ts
import { defineConfig } from "better-supabase/config";

export default defineConfig({
  blocks: {
    // Required by posts; add installs them too.
    "updated-at": {},
    tenant: {},
    access: {},
    comments: {},
    subjects: {},
    reactions: {},
    moderation: {},
    messaging: {},
    // Modes: "managed", "custom". The default is "managed".
    posts: { mode: "managed" },
  },
});
```

## Client

The block has no React entry yet. Its server-side TypeScript is in `better-supabase/blocks/posts`.

## Events

- `post.created`
- `post.deleted`
- `post.merged`
- `post.moderated`
- `post.status_changed`
- `post.updated`
- `post_board.saved`

## Related blocks

Requires: [tenant](https://bettersupabase.com/blocks/tenant.md), [access](https://bettersupabase.com/blocks/access.md), [subjects](https://bettersupabase.com/blocks/subjects.md), [messaging](https://bettersupabase.com/blocks/messaging.md), [comments](https://bettersupabase.com/blocks/comments.md), [reactions](https://bettersupabase.com/blocks/reactions.md), [moderation](https://bettersupabase.com/blocks/moderation.md)

Works with: [outbox](https://bettersupabase.com/blocks/outbox.md), [audit](https://bettersupabase.com/blocks/audit.md)

## Recipes

- [Post board](https://bettersupabase.com/recipes/post-board.md): A feedback board's posts ranked by votes, with an upvote toggle, the roadmap status, moderation state and a New post dialog.
