annotate libervia/pages/_browser/__init__.py @ 1504:409d10211b20

server, browser: dynamic pages refactoring: dynamic pages has been reworked, to change the initial basic implementation. Pages are now dynamic by default, and a websocket is established by the first connected page of a session. The socket is used to transmit bridge signals, and then the signal is broadcasted to other tabs using broadcast channel. If the connecting tab is closed, an other one is chosen. Some tests are made to retry connecting in case of problem, and sometimes reload the pages (e.g. if profile is connected). Signals (or other data) are cached during reconnection phase, to avoid lost of data. All previous partial rendering mechanism have been removed, chat page is temporarily not working anymore, but will be eventually redone (one of the goal of this work is to have proper chat).
author Goffi <goffi@goffi.org>
date Wed, 01 Mar 2023 18:02:44 +0100
parents
children 106bae41f5c8
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1504
409d10211b20 server, browser: dynamic pages refactoring:
Goffi <goffi@goffi.org>
parents:
diff changeset
1 import bridge
409d10211b20 server, browser: dynamic pages refactoring:
Goffi <goffi@goffi.org>
parents:
diff changeset
2
409d10211b20 server, browser: dynamic pages refactoring:
Goffi <goffi@goffi.org>
parents:
diff changeset
3
409d10211b20 server, browser: dynamic pages refactoring:
Goffi <goffi@goffi.org>
parents:
diff changeset
4 # we create a Bridge instance to receive signals
409d10211b20 server, browser: dynamic pages refactoring:
Goffi <goffi@goffi.org>
parents:
diff changeset
5 bridge.Bridge()