Today we open HEY up to the world. It’s @Basecamp’s take on email: https://hey.com/how-it-works 
We started working on HEY in earnest in 2018, and I’m super proud of all the new tech we’ve built for it 🤗
HEY’s UI is 100% HTML over the wire. We render plain-old HTML pages on the server and send them to your browser encoded as text/html. No JSON APIs, no GraphQL, no React—just form submissions and links.
If you think that sounds like the web of 25 years ago, you’re right! Except the HEY front-end stack progressively enhances the “classic web” to work like the “2020 web,” with all the fidelity you’d expect from a well-built SPA.
We speed up navigation in HEY using Turbolinks, the same approach we’ve taken with Basecamp for years: https://github.com/turbolinks/turbolinks But now we’re taking it a step further.
The first change in HEY is that we’ve extended Turbolinks to handle form submissions, eliminating the need to use libraries like rails-ujs. (This was a huge missing piece for folks using Turbolinks outside of Rails.)
The second change is a new system which extends the benefits of Turbolinks to arbitrary, self-contained browsing contexts, scoped to individual elements. This one really took HEY’s UI and development process to the next level.
With our next-gen version of Turbolinks, HEY barely needs any custom JavaScript at all. As I write this, our primary JS bundle is 46.52 KB, gzipped. 🤯 We lazy-load another 49.46 KB for Trix the first time you load a page with a text field.
There’s no getting around the need for app-specific JavaScript, though. For that, HEY uses Stimulus, of course: https://stimulusjs.org 
We’ve enabled full source maps on HEY so you can View Source and see how our Stimulus controllers work, even if you don't have an account. (The JS load on the login screen is the same JS you get when you’re signed in. https://app.hey.com/sign_in )
HTML is central to HEY’s architecture and essential for processing and rendering email. So as part of HEY’s development, we also created a new HTML backend for our Action Text framework with no dependency on Nokogiri or libxml2. 🥳
And our Android and iOS teams have built a new library for bridging HEY’s UI out from embedded web views and into native controls. This lets us do things like annotate links in HTML to turn them into native menu items in mobile apps.
So much new stuff! Now we begin the process of refining and documenting all this new tech from HEY into open-source software the rest of the world can benefit from. I can’t wait to share it with you when it’s ready 😊
You can follow @sstephenson.
Tip: mention @twtextapp on a Twitter thread with the keyword “unroll” to get a link to it.

Latest Threads Unrolled:

By continuing to use the site, you are consenting to the use of cookies as explained in our Cookie Policy to improve your experience.