-
-
Notifications
You must be signed in to change notification settings - Fork 22
Open
Description
When working with PUT POST, etc, we may respond with a Super Turbo Stream response that appends to https://thoughtbot.github.io/superglue/2.0.alpha/fragments/, but at the same time, we may also issue a broadcast https://thoughtbot.github.io/superglue/2.0.alpha/super-turbo-streams/#append.
This can cause duplicate appends, when listening to the same channel for the user. Lets add an option to Superglue JS to uniquely append items. We currently handle Super Turbo Stream appends at
- https://github.com/thoughtbot/superglue/blob/v2/superglue/lib/action_creators/stream.ts#L61 and
- https://github.com/thoughtbot/superglue/blob/v2/superglue/lib/reducers/index.ts#L256.
Much like how options can be passed to append, we can expand it. Perhaps we can add a unique: true as an option?
Metadata
Metadata
Assignees
Labels
No labels