Hot tips are spicy lil' nuggets related to web development and tooling that I share on my twitter account. I've logged them here to make them easier to find.
Figured out the motor controller Byte. First time I've had to write binary 1s and 0s in React.
1K3840273112K
1.5K62626
81935.2K
Controlling a roomba with JavaScript
Wrote the code to control it in the browser via Web Serial API, or on the server with serialport
1.5K8787288103K
37761149
1.1K33K
36925
539533117K
This is a must have editor setting . Here is how I get those coloured indentation / bracket pairs in my editor.
1K762998488K
539601616K
43121
51416K
1671590
I needed some data from social sites, but they don't provide an API
Here is how I scrape data from websites that don't provide an API by (ab)using the page rehydration object
53413K
64614
1.6K106171.9K89K
2.4K1376845K
Tanstack Start doing doing server calls a bit different than React Server Components.
You can write the client and server logic in the same file and it replaces it with fetch calls when run on the client.
No "use client", no errors around using client APIs in server components
717372434368K
44518
4391212K
2548127.5K
I keep importing the wrong thing in VS Code!
Pop an autoImportFileExcludePatterns in your settings file
Super helpful for Radix UI, Drizzle DB adapters, and node:test
35821931219K
379613K
34634209.8K
34913
28613220
I keep importing the wrong thing in VS Code!
Pop an autoImportFileExcludePatterns in your settings file to exclude typescript types
Super helpful for Radix UI, Drizzle DB adapters, and node:test
34913
379613K
35821931219K
28613220
Are you using position: absolute; to overlap elements?
It's almost always better to Use CSS Grid instead!
3.9K366773.2K293K
2.5K3064K
1.8K1165829K
1.1K43
Use CSS Grid to stack items, and visibility: hidden to hide/show spinner.
This approach allows the largest item to size the button, and keeps the button text accessible
2.7K219532K175K
1.3K30K
1.7K78
30723195
One of the biggest problems with UI development is about to be solved!
Customizable <select> brings allows us to create totally custom dropdowns with HTML and CSS.
Accessible, gracefully degrades and requires no JS!