TLDR Web Dev · ARTICLES & TUTORIALS
YES, YOU SHOULD USE SQLITE: NOTION'S CREATIVE SQLITE USAGE FOR 20% FASTER LOADS
Summary from the TLDR Web Dev newsletter
Notion implemented WebAssembly SQLite in its web app. This resulted in a 20% reduction in page navigation latency. To achieve this, its team used Web Workers to offload database operations to background threads and a SharedWorker with the Web Locks API to fix data integrity issues. They also addressed issues of slow disk reads by implementing a "race" between disk cache and network requests.