brainlid
Restore LiveView State on Startup
You are storing some Phoenix LiveView state in the browser. You want to retrieve that saved state as early as possible to improve the user experience.
The approach we used earlier waits for the LiveView to request the client to send the data. In your situation, you know you want the data, so why wait around to be asked for it? Can you have it automatically pushed from the client without being requested? Can you do it in a way that is reusable for other pages and other LiveViews and not just this one page?
This recipe improves the design and even makes it work for multiple LiveViews in the same application!
Popular Frontend topics
Stock Toolkit: Conclusion :: Brain Dump — Geoff’s Technical Notebook.
My toy stock toolkit application is “feature complete” for now. I’...
New
As crappy as 2020 was, JavaScript as a whole still managed to somehow move forward. As the language itself keeps improving thanks to new ...
New
The No-Framework Framework: JavaScript Without React Part I.
How I improved my programming speed by replacing React with plain JavaScrip...
New
The key reason why you (and likely most developers) struggle with CSS, is that you underestimate it.
Underestimating CSS leads to a stra...
New
Last year I created Pomodone, a small time tracking application based on the Pomodoro technique of working in 25 minute intervals. It’s a...
New
Humio software engineers Thomas Anagrius and Jeroen Engels sat down to talk about why they got involved with Elm for web-based front-end ...
New
If you are a long-time React user, you might be wondering for the past few years about when Concurrent Mode/Suspense will ship. The plans...
New
Here’s what I think: if you are building websites, you don’t need React (in most cases).
I have been building websites for over nine yea...
New
You are storing some Phoenix LiveView state in the browser. You want to retrieve that saved state as early as possible to improve the use...
New
What is surprising is that a 14kB page can load much faster than a 15kBpage — maybe 612ms faster — while the difference between a 15kB an...
New
Other popular topics
Instantly view the changes you make to an app with stateful hot reload, and define a declarative UI in the same language as the app logic...
New
Machine learning can be intimidating, with its reliance on math and algorithms that most programmers don't encounter in their regular wor...
New
Learn from the award-winning programming series that inspired the Elixir language, and go on a step-by-step journey through the most impo...
New
My first contact with Erlang was about 2 years ago when I used RabbitMQ, which is written in Erlang, for my job. This made me curious and...
New
I’ve been hearing quite a lot of comments relating to the sound of a keyboard, with one of the most desirable of these called ‘thock’, he...
New
Tailwind CSS is an exciting new CSS framework that allows you to design your site by composing simple utility classes to create complex e...
New
Continuing the discussion from Thinking about learning Crystal, let’s discuss - I was wondering which languages don’t GC - maybe we can c...
New
Use WebRTC to build web applications that stream media and data in real time directly from one user to another, all in the browser.
...
New
A Brief Review of the Minisforum V3 AMD Tablet.
Update: I have created an awesome-minisforum-v3 GitHub repository to list information fo...
New
I’m able to do the “artistic” part of game-development; character designing/modeling, music, environment modeling, etc.
However, I don’t...
New
Categories:
Sub Categories:
Popular Portals
- /elixir
- /rust
- /wasm
- /ruby
- /erlang
- /phoenix
- /keyboards
- /python
- /js
- /rails
- /security
- /go
- /swift
- /vim
- /java
- /clojure
- /typescript
- /emacs
- /haskell
- /svelte
- /onivim
- /kotlin
- /react
- /c-plus-plus
- /crystal
- /tailwind
- /gleam
- /ocaml
- /elm
- /vscode
- /flutter
- /html
- /ash
- /deepseek
- /zig
- /opensuse
- /centos
- /php
- /react-native
- /scala
- /lisp
- /sublime-text
- /textmate
- /nixos
- /debian
- /agda
- /deno
- /django
- /kubuntu
- /nodejs
- /arch-linux
- /ubuntu
- /spring
- /revery
- /manjaro
- /julia
- /diversity
- /quarkus
- /lua
- /laravel









