Steve Schoeffel@steveschoeffel
Yesterday marked a massive internal milestone at Whimsical: we finally removed the Slate text editor code from our app! The final 4,512 lines of code are gone 👋😅
When we first started building Whimsical, we used Slate to quickly get rich text formatting up and running (things like bullet lists and inline text styles like bold, italic, etc.). However, as Whimsical started being used around the world, it became clear that there were some significant shortcomings, particularly related to handling non-Latin languages and also multiplayer editing. Since Slate is an open source framework, it didn’t make sense for us to perennially get by with a bunch of workarounds and patches. We needed more ownership of the code.
In early 2020 (about 2.5 years into Whimsical), we decided to invest in building our own text editor from scratch. This was a massive undertaking—to put it lightly—especially for a team as small as we were at the time. However, we felt high conviction because we care deeply about quality, we planned to build our Docs product later that year, and the text editor sat at the core of the user experience across our growing product suite. We tapped the brilliant and indomitable Nate Hunzaker to lead the charge. Many, many months later—having shed considerable blood, sweat, and tears—he emerged with a custom text editor, built in Clojure. It was a success! We had our very own text editor. But at that point, it only powered our Docs product.
Slate still powered so many other parts of our app… each individual board object (e.g. sticky notes, flowchart shapes, project cards, mind maps, all the wireframe elements), comments, and various text fields in the app UI. So we began the work of painstakingly replacing each instance of Slate with our own “Fresh” editor. This happened over the course of a long period of time as we were building new features in parallel.
Finally, there was only one Slate-powered feature that remained: tables in Boards. But this was one of the oldest and most cobbled-together features in all of Whimsical. It wouldn’t have made sense to invest a bunch of time into swapping out the editor and then still have been stuck with a sub-optimal UX. Thus, we undertook yet another monster project and completely rebuilt our tables in boards from the ground up. This time it was Whimsical OG Miķelis Vindavs who took the lead. Many, many months later and with much toil, the team emerged victorious. Tables in boards now use our own text editor and support a huge amount of rich text formatting. And Slate, which for many years both served us well and was the cause of much frustration, is no more. Huzzah! 🙌