Month: November 2021

  • How to quickly create a Symfony 5+ controller

    A Symfony 5 controller is just a class. You could just use your IDE to create a new class  for you, but you would need  to add some boiler plate code like the namespace and then extend AbstractController and add some use statements etc. Symfony 5+ has a better way though. With just one command […]

  • Ubuntu 20 slow and freezes often

    I’ve used Ubuntu since version 8 or about 2009/2010ish. It used to be super fast. You used to be able to run it on ANYTHING. It was easy to use. I can’t take the damn slowness these days. Update. Apparently Gnome is the culprit plus some other useless crap. Some say Kubuntu is faster. I […]

  • Faking Enumerations with Vanilla javascript

    Faking Enumerations with Vanilla javascript

    What is an Enumeration? An Enumeration is a way to create a limited list of options to choose from.This is useful for keeping a list of field names for a form so you can use javascript to animate something for example. Having a limited list of options is helpful so that you can eliminate bugs […]

  • Php Backed Enums don’t forget to call value

    Php Backed Enums don’t forget to call value

    The one thing I don’t like about new PHP enums is, if you forget to call ->value you get exceptions “object can’t be converted to string” It is entirely too easy to forget to call ->value. This means in places where I refactor code I have to remember to call ->value. Hence the article title […]

  • Working with your apps local image assets in Symfony 5+

    Working with your apps local image assets in Symfony 5+

    This article is mostly about managing your apps personal images and SVG files that it uses in your User Interface. It also explains how the Assets system works to the best of my abilities and discoveries. This is the best info about assets, I have found in the docs about assets. It doesn’t mention some […]