Case Study

Turn the Page: A Digital Bookshelf Built in React

Summary: I made the digital bookshelf I wanted and opened it up to everyone. Turn the page lets you add books you've read, are reading, and want to read, to your digital bookshelf. There's no social, reviews, no ratings—just your reading list presented in a modern, minimal layout. Oh, and of course there's also an AI book recommendation feature based off of your personal reading history.

Website screenshot

Turn the Page is a free platform to track your reading list. Make your free account at www.turnthepage.app.

Features include:

  • Search and add any book (English only for now).
  • Track when you read it and the format you read it in (eBook, audiobook, physical).
  • Keep individual books, or your entire book shelf private.
  • Browse and track the books you've read on the top book lists.
  • Get AI generated recommendations for what to read next.
  • Easily export all your data.

Background: My Story, My Books, My Data

I'm a list-maker. Always have been. My life is a series of cataloged entries: tasks, project concepts, restaurants visited and yet to visit (see I-eat-ithaca), every run, every workout, every book read, etc... I've learned one important thing over the years: The shiny new app that promises to make the list maker's life easier will eventually loose its sheen, and when that happens, you'll be stuck copying and pasting your data out of that app.

This pragmatic realization led me down the path to find a better way to manage my reading list. Until now, a simple Markdown file has served me well for this purpose. I use Obsidian for all my list making. While the data is portable, "aesthetic" isn't exactly in its strong suit and there's a satisfaction to looking at your bookshelf that is lost in the digital world. The internet does offer multiple options for book-tracking platforms, but they often come with more features and noise (social) than I need, and crucially, a less-than-ideal position on data portability.

My requirements in a book list are simple: a straightforward method to display and maintain my book list, coupled with easy data exporting—that's why I made Turn the Page.

Features: More Than Just a Book List

Elegant Bookshelf

At its core, Turn the Page is a digital bookshelf. Books are neatly organized chronologically, separated by year, and display the cover, title, author, and read date for each. You can track books you've read, are reading, or want to read, and easily move them between those states.

Curated Lists of Award-winning Books

One notable addition is the inclusion of several prominent book lists—Pulitzer Prize winners, Hugo Awards for best novel, the NYT Readers' Choice list, Booker Prize winners, and the Giller Prize winners. You can browse these and quickly see which titles you've already checked off. This has proven to be a great way to discover my next read.

AI Generated Reading Insights and Recommendations

If the prize winning lists don't fit your taste or your mood, then there's also an AI-generated reading analysis and recommendation tool. This feature offers a summary of your reading preferences, suggests potential new genres or authors to explore, and recommends five new books based on your history.

One-click Data Exports

Data portability is non-negotiable. Easily export all your reading data as text, markdown, or JSON data.

Data Privacy

Change how your username is displayed, set your bookshelf as public or private, set individual books as public or private.

Website screenshot

The Stack: Some Old, Some New

Building Turn the Page was an opportunity to use some tools I was familiar with in some new ways and to try out some wholly new things as well. The frontend is built with Next.js and hosted on Vercel. For data storage, I opted for Postgres on Supabase, and authentication is handled securely with Auth.js using either Google or GitHub OAuth. Prisma ORM kept my database interactions type safe. And some test driven development was implemented using Jest.

This project also provided me with my first opportunity to try out Tailwind CSS. I'll admit, I went into it with some preconceived opinions about Tailwind, and while I gave it a fair shot, my initial preconceptions largely held true – I'm still not its biggest fan! But just like literary tastes, to each their own.

Integrating the Google Books API was crucial for finding book data, which, when you add a book, is imported into the database and served from there from that point on.

Another first for me with this project was integrating an LLM api for the AI generated recommendations. The API interface is straight forward enough, the interesting challenge was the trial and error process in prompt engineering and the wide variability in responses based on small input changes. Due to the non-deterministic results, some prompts which appeared to provide good responses, upon further testing would reveal to be inconsistent, returning the same recommendations for very different book lists, return books already on the list, or be prone to hallucinations about the input data itself.

One of the most significant technical hurdles in this project was leveraging caching effectively. Trying to keep the costs as close to zero on the third-party services I'm using meant I needed to be smart about minimizing queries and API calls. The challenge was maximizing caching while still ensuring that dynamic content is refreshed and displayed correctly across individual users. It was a fascinating puzzle to solve.

Embracing My Reading Taste (Even the Space Operas!)

One wholly unexpected discovery from working on this project has been my bashfulness at sharing my reading taste (and conversely, how many people share my tastes). Demoing Turn the Page often comes with a slight blush. My literary tastes aren't always the most "highbrow". My preferences lean heavily towards hard sci-fi and epic space operas. The last few years of my life has included a significant number of long drives between Boston, Ithaca, and Toronto (each a solid five-hour leg). Nothing makes those miles disappear like a gripping sci-fi action audiobook.

Now, thanks to Turn the Page, my literary diet is on full, public display. If you like a blend of sci-fi and programming on your reading list, check out my bookshelf.