Full Stack Tutorial
The journey from an idea to a fully functioning web application is made surprisingly short with the right tools. Learn how modern webapps are built, and how to create and deploy your own in a matter of hours.
Building a web application involves more than creating a user interface. Behind the scenes, application logic needs to be executed, data stored, and information exchanged between users. Full stack development brings these layers together, giving you control over the entire application rather than just one part of it.
Learning full stack development is often a daunting undertaking, not because web applications are inherently complicated, but because of the sheer number of technologies and tools commonly involved. Much of this complexity can be avoided.
A typical web application consists of two parts: the frontend running in the browser and the backend running on a server. The frontend uses HTML, CSS and JavaScript to present information and handle user interaction. The backend provides shared application logic, processes requests and stores data persistently. The two communicate over the network, allowing users to access and interact with the same application from different devices.
Full stack development brings these parts together. By choosing technologies that complement each other, we can build complete applications with surprisingly little code and infrastructure.
Build fast, deploy fast
For the frontend, we use the Vue framework, which builds upon familiar web technologies – HTML, CSS and JavaScript/TypeScript – and makes it remarkably easy to create interactive user interfaces. Together with Pinia, it takes care of keeping the interface in sync with the application’s data. Compared to handwritten JavaScript, its components provide useful structure for larger applications, while reactivity keeps us from drowning in the glue code of change event handling and rendering updates. Our code expresses what we are doing, without unnecessary boilerplate for things the framework can handle for us.
Why not React, Mongo or SQL?
Popularity does not necessarily translate into productivity. While these are more widely adopted technologies, we favor Vue for its simplicity and ease of development, and Kanta for its speed and ability to work directly with Python data structures, and without a separate database server. Our choices are driven by how quickly we can build, deploy and maintain a complete application.
On the backend, we turn to FastAPI, a relative newcomer that has already become the leading Python web development framework – and for good reason. It enables us to connect browsers and other API clients to our server-side business logic and database with very little code.
The fastapi-vue-setup script adds the glue to make the two work smoothly together.
To store our application’s data, we use Kanta, the only database that is built on Python async programming, best suited for FastAPI apps. It allows working with native Python data structures, without having to translate between different data models, learn a query language or maintain a separate database service.
A particularly important aspect of this stack is how easily an application can be taken into production. The frontend and backend are distributed together as a single Python package, ready to run on any suitable server. There is no Node.js runtime, database server or collection of containers to set up and maintain.
And finally, all of this runs far faster than one might expect of a reactive JavaScript stack bundled together with a Python backend. By the time you even have to think scaling up, you’ll have enough paying customers to cover any optimization or conversion costs. We are not in Django territory anymore.
From idea to application
We will build Poll Box from scratch. It starts as a simple interactive page in the browser and evolves into a multi-user application where votes are shared instantly and preserved across server restarts. Each new concept is introduced when it serves a practical purpose.
In a few hours, you will have built and deployed a complete application yourself. More importantly, you will know how its individual parts work together and have a foundation from which to build your own ideas into working software.
Let’s get started by setting up the development tools.