Personal Helper Code Snippets

Personal Helper Code Snippets

Tech stack: php, SCSS

Year: 2021

Source code

As I worked on different websites and tasks, I noticed some repeating patterns. I extracted them out to reduce time.

What this is

This project contains boilerplate codes and snippets that helps me start up and work on new client projects more quickly and easily. As of the time of writing, this includes:

  • SCSS directory containing scss boilerplate for creating custom styling on client snippets
  • mod_boilerplate directory containing boilerplate files for creating a custom Joomla module.
  • .vscode directory containing snippets for my development, specifically php/Joomla snippets.

I intend to update this repository as I notice more repeating patterns in my workflow.

Why it's made

As a web developer for Sandman Media for over a year, I have worked on numerous websites for clients, and every time I start a new project, I notice myself repeating the same things over and over again. I would start with a blank Joomla projects, setting the layouts, adding contents, adding some scripts and overriding the styles using custom SCSS files. The styling code is especially repetitive, since the starting setup code usually stays the same across websites. Therefore, I extracted some of the repetitive patterns I noticed into this directory for me to have an easier time starting a new project.

Similarly, when I need to create a custom Joomla module (such as a module that fetches and display stock prices), I would also need to end up creating a blank Joomla module structure at the beginning. Therefore, I have the blank mod_boilerplate module for me to start with.

As for the VS Code snippets, I created them when I started fiddling around with creating a custom Joomla components. I realized how few extensions there are for php in general and Joomla in specific, so I just added a few snippets that I found myself using the most when working with Joomla components. The snippets are by no mean exhaustive; however, as I have not spent much time yet on developing custom Joomla components.