# `Kotoba.Collab`
[🔗](https://github.com/hattoriai/kotoba/blob/v0.5.0/lib/kotoba/collab.ex#L1)

Collaboration for Kotoba with Phoenix as the document authority.

Import `kotoba/collab` once in the application's JavaScript, mount
`Kotoba.Collab.Channel` on an application socket, and pass `token/3` to
the component's `collab` attribute. See the Collaboration guide.

# `content`

Reads the current durably accepted content and revision for a form commit.

# `content`

Reads the exact accepted revision posted by a collaboration form.

# `token`

Makes short-lived join credentials from the LiveView's authenticated user.

Options: `:user` (required), `:role` (`:write` or `:read`), `:socket` (the
socket's path, `"/kotoba/socket"` by default) and `:max_channels` (that
socket's `:max_channels_per_transport`, 100 by default).

# `transact`

Applies backend operations through the same validation and persistence path.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
