10906 shaares
392 private links
392 private links
It was one of those moments where something you once knew suddenly clicks again with fresh significance. Here was a URL doing far more than just pointing to a page. It was storing state, encoding intent, and making my entire setup shareable and recoverable. No database. No cookies. No localStorage. Just a URL.
Good candidates for URL state:
- Search queries and filters
- Pagination and sorting
- View modes (list/grid, dark/light)
- Date ranges and time periods
- Selected items or active tabs
- UI configuration that affects content
- Feature flags and A/B test variants --> I never though about this one
Anti-Patterns to avoid:
- state only in memory SPAs
- sensitive Data in URLs
- inconsistent or opaque naming
- overloading URLs with complex state
- breaking the back button