Hello, hello. I'm so excited to show you blitz.js. Let's get into it. I was building react apps for a number of years, full stack react apps, and I happily put up with the complexity and struggle required to do so. And I did that because I loved building user interfaces with react more than any other way.
But the honeymoon ended and I became increasingly frustrated with all the complexity. Things like rest APIs, graphQL APIs, multiple servers, deployments, state management, configuration, libraries, tooling, everything, just anything that got in the way of me building features slowly depleted my morale. I really wanted to love full stack development again. I wanted to be extremely productive again. I wanted to focus on building features instead of all this other unnecessary configuration and conglomeration in my app.
So I decided enough was enough and I set out to build the best possible developer experience for full stack react apps. So there were two things that I really wanted to have for this experience. That I was going for number one, it had to be a monolithic. Monolithic means there's one thing to think about, one thing to build, one thing to deploy. It's everything is together and cohesive, and it's just much simpler. I got into web development through Ruby on Rails, which is monolithic. And so I know the productivity benefits that you gain from that. And I wanted to get back to that. Secondly, is I wanted to get rid of the API. The API layer in React apps is one of the biggest sources of complexity, confusion, headache, heartache, just pain. And so I wanted to get rid of that. It's amazing. Like we don't realize how much that API layer slows us down and gets in the way until you don't have it anymore. And then you're like, wow, this is amazing. And so I could, I knew a sense of what that was like because of Ruby on Rails, there's no API, you can talk to your database directly from your view if you want to, not recommended, but you can. And so this was very critical.
But how can you accomplish this with React? At the time, so this was back when I started Blitz. Like 14, 15 months ago, I was thinking how can we do this? The only way I knew was server-side rendering. And that's how Ruby on Rails does it. And so, well, I was like, we could do this. At the time Next.js had just added the get server-side props and it would just seem like that would be a good approach. So when I first announced Blitz, I said, all right, here it is. What it is, I had an initial prototype that was server-side rendered, but I didn't love it, I didn't love it. And that was critical for me. I wanted to, I wanted to love what I'm using on my day, in my day-to-day work, you know? So me and the other early Blitz contributors were hashing this stuff out, talking about what would the architecture look like? Would it be a model view controller? Would it be, what would it be? And one day I was laying on a, laying in a hammock in Thailand, pondering this and I asked myself, what would this look like if it was easy? So, as I sat there dreaming about what could I possibly, what would be easy? I got this picture in my imagination of just a function that runs on the server, that talks to the database and just importing that function directly into my front end code, my react components. And then the framework would magically make that thing work, make actually like put an API layer in there. And, but the user wouldn't have to deal with it. And so I was like, wow, that's a cool idea. I wonder if I can make it work.
Comments