Adding a spaghet-o-meter to my projects

Ever since I started coding in 2016, my coding style has generally leaned towards coding fast, but also making a mess. It’s cool to say that I was able to make in about 120 hours of coding time – but you should also know that it’s a 3000-line inline script tag. That’s spaghetti code.

I’ve realized that I write a lot of spaghetti code that’s somewhat unmaintanble in the long run. I definitely don’t use object-oriented & reusable code throughout my scripts – which is a big issue that I need to rectify.


That’s why every project that I’ve made before late 2020 will now include a Spaghet-o-meter in the readme file. For, the Spaghet-o-meter is in the article.


The Spaghet-o-meter is a scale from 1 to 10 estimating the spaghettiness of the code I’ve written. A 0 means there’s almost no spaghetti code, with lots of object-oriented & reusable code. A 10 means it’s raining spaghetti from the sky – there’s no reusable code at all. Estimations are taken from my experience maintaining code, and from guidelines on Stack Overflow about the signs of spaghetti code.

Below the Spaghet-o-meter, I’ll briefly explain the reasoning for the score, and ways to un-spaghet the code.


From late 2020 and on, any new projects will be designed in a more object oriented fashion. And hopefully the spaghet-o-meter will start heading towards 0/10 territory.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.