websockets reconnect after element removed · Issue #161 · bigskysoftware/htmx-extensions · GitHub
Skip to content

websockets reconnect after element removed #161

Open

Description

@goertzenator

After an element with a ws-connect attribute is removed, the socket connection is closed but then immediately reconnects. If a long lived web page adds and removes many elements with ws-connect, every websocket that ever lived still keeps reconnecting.

This behavior seems to have been added by this commit.

Activity

  1. Telroshan commented on Apr 29, 2025

    @Telroshan
    Collaborator

    Seems like this was an accident indeed @goertzenator

    If you are interested, please feel free to open a PR to fix that, along with a test case so we prevent any future regression!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions