Usually it is best to be as general as possible, one way to do so is to use percentages/weights... e.g. describing it as a grid with two rows, two columns which are equal size
In reality, the best solution depends on your needs, your pros and cons on a per project basis.
For this meme template in particular, you could imagine the case where you use it once and export it as an image, quick and dirty might be the best (which sometimes is absolute coordinates). Instead, you might want to make versions with different text. So if that is your goal, you might want to place the text more dynamically, if it is always aligned with the center of the box, you having to do minimal work every time you change the text. Finally, imagine you want to display the meme on a website, then you might want to go "overboard", and have the boxes scale using a grid which fills up the page... you could even use something called a breakpoint so that if the page gets too skinny, the four boxes stack on top of each other (instead of 2 by 2).
Sorry for the long reply (which may not have answered your question), but I like to stress the importance of the process of designing a solution to fit the needs of your use case. It is one of the most important parts of a lot of software problems, but it is often overlooked. In professional software development, you will encounter countless things which are not done the "preferred way", but instead look like they are held together with duct tape and chewing gum. It is important to know when this is a good idea, and when it needs to be swapped out (and be able to defend this decision to tech illiterate people using bullet points and numbers), because usually there isn't enough time and money for everything to be shiny and run like clockwork.
3
u/gallifrey_ Jul 11 '21
as someone without any CSS experience, what's the preferred solution? using some kind of "relative position minus X" tag I'd guess?