Designing Something New
I don’t think there’s something like a completely new, original and revolutionary concept in web design these days. So that’s absolutely not what I’m trying to do, not here and not on other projects. I am currently working on a sort of modular CSS structure for myself. A framework if you will. I might go and use it for this blog so that it has a use and so that I can extend it with things that I myself need. For now, it’s got a big Homepage pretty picture with a title, like you can often find on small blogs or online business card pages, there’s a flat cards layout, it responds to device size with navigation and layout, and I even started a little preferences thing.
I can choose if I want the article/post/page cover image to be above or below the title, in the overview. This is done in Jekyll, it checks if a variable is set true or false, and picks which version to render. Because this is all happening in a static site generator (SSG), nothing needs to be calculated when the site is visited. But doing this means I can future-proof the framework, use the exact same files for different projects without even changing a single character. That’s what I’m going for.
To me, CSS has always been one, two or maybe three static files that I add on to when I need something new. These files are included in the header like you’re supposed to do in HTML. But I’ve been learning about internet stuff and found SASS. With an SSG like Jekyll, you can make a million CSS files that make up the whole website, and when rendering the website, the SSG picks what is actually used and compiles it into one neat CSS file. At least that’s what I think happens, it might just be squeezing them all together no matter the content.
This means that my new framework thingy I’m working on currently has 6 SCSS files, different parts are split up in to different files. The big Homepage header is one, the navigation is another file, the cards layout is in yet another file, and there’s a general file which contains a couple of variables, colours and sets the main layout. This genuinely saves me so much scrolling time, using this system instead of a single massive file.
Keeping it compartmentalized seems important, no quick fixes in the header file if it really needs to be in the general file, so that it’s easy to look things up and change them. In this process I did need to find a certain part in a file, I didn’t remember which file. I use Atom by GitHub for this, and I found the most amazing feature. I can not just ctrl+f search in a file, or find and replace. I can Find in Project.
I can type something that I need to find, let’s say “imsge.jpg”, to see where I typed it wrong. Using Find in Project, I get a list of all the instances of “imsge.jpg” in the entire project. I find this amazing, even though it’s probably a trivial function. It saved me many seconds today.
I have been thinking about a headless CMS for Jekyll. What that would mean is a nice admin-like interface where pages can be made, posts can be written and stuff. I would not need it to have a whole what-you-see-is-what-you-get design part, just write and publish pages. But I can’t figure out which one I want to try. There is Strapi but the Jekyll plugin doesn’t support the latest Strapi version (v4) and has been abandoned. Which sucks. There was something else I came across, Jekyll-admin, but that runs alongside the development version of the site. So I can’t just go to admin.example.com, write an article and let it compile. That also means that I would not be able to use it for clients, if I were to make a website for someone else.
I might have to develop my own Content Management System. Do not feel like doing that. I’ll see if I can find something else that just makes Markdown files, which can then just be pulled into Jekyll for compilation.
A personal thing
Yesterday I went for drinks for the first time in almost 3 months, with bars slowly opening back up here. It was so strange to be back amongst people but I had a really good time. As if the whole pandemic was over, just for a couple of hours. Even though there were just 4 of us and we had to stay seated.
For me, that’s the best way to do bars though. Just chill.