https://github.com/danr/viable
A viable alternative to frontend programming.
https://github.com/danr/viable
hot-module-reloading python-frontend
Last synced: 5 months ago
JSON representation
A viable alternative to frontend programming.
- Host: GitHub
- URL: https://github.com/danr/viable
- Owner: danr
- License: mit
- Created: 2021-03-09T19:56:44.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2022-12-08T20:36:52.000Z (about 3 years ago)
- Last Synced: 2025-01-23T15:39:48.912Z (11 months ago)
- Topics: hot-module-reloading, python-frontend
- Language: Python
- Homepage:
- Size: 90.8 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# viable
A viable alternative to frontend programming.
Viable updates outdated elements in the DOM using a DOM differ. It also
updates the values of input fields, with the exception of the currently
focused input field in the client. This allows for the sending of updates
to the backend on keystrokes to an input field.
In terms of session and variable values, the software uses session storage
to store state in the frontend. This is necessary because cookies are shared
between tabs, and session storage allows for duplication of tabs. If a new
tab is created, the session storage is empty and variables are initialized
with default values.
For persistent storage across windows and tabs in the browser, the software
also uses local storage. If a new tab or window is created and the value
of a variable is retrieved, the session storage is empty and the value from
the local storage is used instead. (Currently not implemented)
Cookies cannot be used for this because they have a maximum size of 4
kilobytes, whereas session and local storage have a minimum size in the order
of megabytes.