Have you setup a container or configured Monolog anywhere? You might want to have a look at slimphp/Slim-Skeleton and see how it is wired together in that example, and here is the index.php from that example.
In the First Application Walkthrough you referenced, have a look in that index.php. The logger is configured on line #22, then you can see it used on line #39.
In your example, you would likely want something like this (I have not tested it):
It would be great if they had a version for running it in public_html an not a sub-directory, and yes I know I could just .htaccess this but rather not.
just rename public to public_html (or move the index.php file) and it should work fine, the folder name isn’t hardcoded into Slim anywhere. I run things from a directory called content and don’t need to change anything else.