ReactJS Pitfalls #2 - using useState Instead of useRef, useCookie, useLocalForage
Suppose you want to persist data across sibling nodes. The next logical step is to use the parent to save the data. You may end up falling into a pit by managing the Child's state in the parent, which ends up causing performance issues. To ensure that the value held by the parent does not cause a re-render but still passes to the child on a remount, you can use useRef in the parent component and useState in the child component, OR you can avoid the parent altogether and use useCookie or useLocalForage in the child component to persist across entire app sessions rather than just sibling nodes. ... https://www.youtube.com/watch?v=IpwdQiEAWJE
The third demo for my music player, Music Caster.
There's also a Web GUI I forgot to demo. Click or scan the QR code, it's very intuitive.
Finally, 99% done with this project after 1.5+ years and a fresh demo too.
Download Music Caster https://github.com/elibroftw/music-caster/releases
...
https://www.youtube.com/watch?v=5xwHkLPgvtQ
I'll also try to make the thumbnail for this video without Photoshop ?.
Windows 11 emojis are out of line!
New laptop is the Razer Blade 14 (2022). I tinkered with OBS for a bit
and settled on -0.10 for gamma and -0.0020 for brightness. It's close enough to what my display and the last 10% improvement is tough to get anyways.
...
https://www.youtube.com/watch?v=Tq9qpA2QOTI
I quickly go over how to use Deserialize and Serialize Structs as well as how to abstract your code and make it all tidy.
https://github.com/elibroftw/rust-backend-tutorials/
...
https://www.youtube.com/watch?v=F6r3GleRewU
One thing to add is that the quality is so good you don't want to hit it when it freezes or slows down.
Software like discord works better on the browser on this laptop.
Battery Life: 3 hours 50 minutes when playing YouTube and using Microsoft Word.
Todo chapters.
...
https://www.youtube.com/watch?v=yUD-R7tB4w8
I've had this video idea for more than half a year and its finally come to fruition. Enjoy.
build.yml: https://raw.githubusercontent.com/elibroftw/modern-desktop-app-template/master/.github/workflows/build.yml
Template: https://github.com/elibroftw/modern-desktop-app-template
Google Keep Example: https://github.com/elibroftw/google-keep-desktop-app
For donations, I accept Monero or Music Caster translations (work for work)
monero:84PR6SkYd5zaFLKDjAFrQfbaAg2c7SV3q3XDZ15QCpEZUggrN4YzY7n8m9XC3deXjo41yWHTm1LrsUpPTYGnRQbD9Cwp8En
00:00 Agenda
00:33 Optimization 1 (allowlist)
03:00 Optimization 2 (Cargo profile)
04:11 Automated Cross Platform Building
06:10 Workflow File Explanation
08:37 Optional: .nvmrc file
10:10 Workflow File Explanation
14:01 How to start build (tagging)
15:30 Manual publishing a release
16:14 Next video is on auto-update
...
https://www.youtube.com/watch?v=rHK2keBNSHo
The core concept is verifying that the post requests for state changing routes contain a server generated token as proof that the request was not forged.
pip install --user Flask-WTF
https://flask-wtf.readthedocs.io/en/1.0.x/
...
https://www.youtube.com/watch?v=IkzdjP9wWas