My Authors
Read all threads
It's crazy that providing URLs that can be used to link to content is somehow an advanced technique in this weird SPA-infested world we live in these days
Like the ability to link to things is a stretch goal now
We still get to make fun of help pages that tell you to "go to menu X, then option Y, then scroll to Z" rather than just linking to the thing they're talking about, right?
Tip for SPA developers: if you put the work in to get actual URLs working, SO many features become SO much cheaper to build.

"Lets prompt the user to update their credit card": now it's a static alert component with a link to the billing section!
Not to mention URLs give you a best-in-breed cross platform "share" feature across all known devices

(You did remember to implement enough of a server-side rendering step to power preview cards in sharing apps, right?)
Here's a really cheap trick for URLs in SPAs that no one seems to be using: query strings! Like for old school PHP!

You get real (not hashbang) URLs without needing to configure your server to respond to many different paths.

Demo: owlsnearme.com/?place=108878
Query strings can also provide an inexpensive way of implementing link sharing preview cards with as little code as possible

(I still think you're better off building a crazy-fast-loading cheap-phone-friendly good-internet-citizen non-SPA though)
Missing some Tweet in this thread? You can try to force a refresh.

Enjoying this thread?

Keep Current with Simon Willison

Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

Twitter may remove this content at anytime, convert it as a PDF, save and print for later use!

Try unrolling a thread yourself!

how to unroll video

1) Follow Thread Reader App on Twitter so you can easily mention us!

2) Go to a Twitter thread (series of Tweets by the same owner) and mention us with a keyword "unroll" @threadreaderapp unroll

You can practice here first or read more on our help page!

Follow Us on Twitter!

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just three indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3.00/month or $30.00/year) and get exclusive features!

Become Premium

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal Become our Patreon

Thank you for your support!