Skip to content

Commit

Permalink
Disable implicit attach for Chat
Browse files Browse the repository at this point in the history
  • Loading branch information
lawrence-forooghian committed Nov 7, 2024
1 parent 412b40d commit 629907b
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions textile/chat-features.textile
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ h2(#general). General Principles

* @(CHA-GP1)@ As far as is practicable, the implementation details such as underlying Realtime Channels should be hidden from the public API. This allows developers to interact with Chat without having to understand many low-level primitives.
* @(CHA-GP2)@ The public API should avoid implicit operations as a side-effect to some other operation. For example, adding a subscriber to messages in a Chat Room should not automatically trigger that Room to attach. This is in contrast to the current core SDKs. Avoiding side-effects provides a clean, easy to understand API.
** @(CHA-GP2a)@ @[Testable]@ Whenever the Chat SDK fetches a realtime channel, it must do so with the @attachOnSubscribe@ channel option set to @false@.
* @(CHA-GP3)@ Wherever possible, Chat features should be exposed in the public API as properties of their parent. For example, @messages@ would be considered a property of a @room@ object. This allows for greater composability and extensibility in the future.
* @(CHA-GP4)@ Avoid overloading methods and optional parameters. Prefer object-type parameters wherever practical and idiomatic.

Expand Down

0 comments on commit 629907b

Please sign in to comment.