Dad's Homemade Pizza: How to start (and finish) a project without getting overwhelmed
When you start a new project, do you ever find yourself spending hours obsessing over what tools to use?
Choosing just the right tech stack?
File -> New Project in Visual Studio and stare at the new project templates. Should you start from scratch with an empty project? What about that .NET Core web app template with an Angular front end? Yeah, Angular is cool, let’s try that…
Hours or even days go by and your being swallowed alive by Angular Directive tutorials and you haven’t written one line of code.
As developers, we love to find the perfect library for the job. We want to save time, not recreate the wheel - but this obsession with tech stacks and tools can quickly have us lose sight of our original intent:
To build something.
What is a project if no one ever gets to use it?
We don’t want that.
Over the years I’ve taken an approach that helps to keep the wheels moving, minimizes distractions, and ultimately gets the project done and out the door.
Dad’s Homemade Pizza
In order to have a nice metaphor to tie this together, I’m going to go with my Dad’s homemade pizza. He hasn’t made it in over 15 years, but it was a family classic. Made using crust from a ready-mix bag, baked in a rectangle cookie sheet, with one or two toppings made out of whatever vegetable was around at the time.
Start with the crust
Starting with the crust means putting together a very basic data model for storage. Most apps require some kind of storage, maybe you’re using SQL Server, or SQLite like on my latest project.
Create the bare-minimum set of tables and columns for your app.
I’ll keep stressing bare-minimum – don’t allow yourself to get sucked into adding accessory. If you’re absolutely going to need a user profile table, have one with just a
name column. You can add
zipcode and all that jazz much later.
Ok, so you’ve got your crusty foundation ready. Time to build on to that. Notice how we aren’t thinking about ORMs or any other special tooling yet.
Add the necessary sticky stuff
Your sauce and your cheese. This is, again, the bare-minimum needed to interface with your storage. You’ll need some kind of data layer to actually save and retrieve your data.
I like to create models to match the tables and then a basic repository.
If you’re creating a web-based app that will have a graphical user interface, you may also need to create some kind of API (ASP.NET Core controllers are perfect for this) that your front end will be calling.
Remember – bare-minimum. Don’t worry about security or any external API calls until later. Stick to dummy data.
I want to point out that there are many boilerplate generating tools out there that can speed those steps up. I’ve tried some of them, but I end up deleting a lot of the generated code and ultimately prefer to put something together myself since it doesn’t take long and gives me a better feel for the project.
Lay down one pepperoni at a time
The previous steps involve gluing the foundation of your app together. The crust, sauce and cheese.
This step is the bulk of the work. One pepperoni is analogous to one user task. One thing that your user would do within your app. Using the To-Do List app example, one user task would be adding a To-Do item.
To prevent myself from getting side-tracked, I like to use a sticky notes app or an actual physical pen and paper and right down all the fundamental user tasks I will need. Then I work on them one at a time until they are done.
You might also choose to draw a mock-up of the user interface and work on sections of it at a time.
By actually implementing core app features, you’ll inevitably discover gaps in your earlier layers that need to be created. Now is the time to build them as-needed.
As-needed and bare-minimum are good mottoes for this process.
Begin using tools and libraries AS-NEEDED
I couldn’t think of a good pizza metaphor here… Can you?
If you begin a task that you think a library or tool exists for and that it would be a mistake to roll-your-own because of how complex your task needs to be, go ahead and find one.
Do not spend too much time looking. Find 1-3 that look good and just pick one and keep building.
If you have a user interface, consider at this point how complex it will need to be. How interactive is it? Is it just displaying information?
If you find that your UI is going to be quite complex (think real-time updates, facebook, news feeds) this might be a good time to consider using a front-end framework like React, Angular, or Vue. If it’s not that complex, then keep it simple, stupid (KISS).
Make the pepperoni smiley face LAST
Appearance, glitter, animation, bonus features – save all of that for the end when you actually have time to diddle around. You will burn out if you mess with that stuff too early.
Slap yourself on the wrist if you find yourself nudging a
div over by 3 pixels so it aligns.
When you’ve reached the end, that is the time for polish, but don’t be afraid to ship your app and let the world start using it. Many apps don’t make it out the door because the creator wants it to look juuuuust right.
Instead they just had files. And text.
Sad, I know, but fortunately that’s not you.
You get shit done. You ship.
You eat your pizza.