React and Vue re-visited

After re-creating my portfolio with Gatsby (which uses React) and building an app for a client in Vue I feel I have more knowledge about the two JavaScript frameworks to give an informed opinion on both.

When I was first starting out using these sort of frameworks I wrote this article on my thoughts.

I would argue that React is quite an old framework. This leads to some benefits. There are a lot of tutorials online and a lot of examples and plugins that you can download to extend React. I may not have grasped the framework fully but I feel that because it’s an older framework, and it grew in popularity so quickly, it has become bloated and more difficult to understand. React has so many core features now, compared to when it first launched, such as hooks and state, with many more features planned. There are at least 2 different ways of doing things, such as the simple task of creating a component. You can either create a functional component or a class component. This means many tutorials are incompatible with each other, even when all of React is written in the same language, JavaScript. When initially starting out I didn’t like how you had to buy into the whole React eco-system. It was much like deciding to buy a MacBook. Coming from building static sites and having the option to use some PHP to make them dynamic, using React felt like I jumped straight into the deep end and had to use JavaScript for everything. There are even plugins that extend React enabling you to write CSS in JavaScript. I love CSS!

Vue was one of the first JavaScript frameworks I used. I started out by forking my lecturers class notes which used VuePress. I had no idea what I was doing but I managed to follow his tutorial and get up and running. I then used Vue to redo my portfolio on my photography site. This was more to complete a task and I was implementing it on a pre-built website, which uses PHP, and jQuery, it wasn’t an experience of building a SPA or a site from scratch. This experience came when building an app for a client. Building it with Vue was like a breath of fresh air. Vue template files split CSS, HTML, and JavaScript, just like a static site. The HTML doesn’t have to be JSX, but it can be. I use the V-If statement so much to conditionally render HTML. The Vue data attribute is a god save for managing variables and data within the application. Vue devtools make it really easy to manage too, it’s like a mini database on the Front-End. I understand how the Vue lifecycle works and know when to execute my code. No more worrying about whether I can call componentDidMount() on a functional component.

In conclusion, both frameworks have their merits but I’ll be using Vue from now on.

What is a Front-End Developer?

I’ve been asking myself this question a lot recently after applying for quite a few web development placements.

The experience has been enlightening, teaching me a great deal about the industry. I’ve been reflecting on what I’m good at in web development and what I enjoy.

Whilst freelancing I’d describe myself as a Full-Stack Developer. I have to deal with the client/project. Come up with designs. Create a website for them. And sometimes create a Back-End API. Being a freelancer I have to be skilled in the entire process of web development. In a junior role I wouldn’t be expected to work on a project in that way.

When I first started interviewing for roles I called myself a Full-Stack Developer. Most companies needed someone to create APIs and write Object Oriented PHP.

I then started calling myself a Front-End Developer and companies were still getting me to do PHP competancy tests.

In my opinion, a Front-End Developer specializes in languages that run in the browser: HTML, CSS, and JavaScript. This has shifted in recent years and now encompasses the array of JavaScript Frameworks out there such as React, Vue, Angular, and Svelte. I’d also argue that a Front-End Developer should have a great deal of knowledge in SEO, Website Optimization, and Accessibility.

I would define a Back-End developer as anyone that specializes in languages that run on a server. I.e. PHP, Python, and Ruby.

With the Jamstack turning heads all across the development landscape Front-End developers can now work on projects that historically needed a Back-End developer.

In conclusion, I find myself enjoying what I would define as Front-End Development. Practising my skills with JavaScript Frameworks, and optimizing my sites for accessibility and speed. But the role of a junior Front-End Developer seems hard to come by, at least in my experience, with companies expecting proficiency in sever-side languages.

TL;DR

Front-End Developers focus on languages that run in the browser.

Back-End Developers focus on languages that run on a server.

Animated mobile menu

In quite a few of my projects I’ve needed a quick and easy way of making a menu which scales onto mobile. I like the style that android apps have; the animated drawer, so I have replicated this.

The menu is swipe aware using Hammer.js which means if you swipe right on mobile then the navigational drawer will slide out and if you slide left, then it will disappear.

I created a Gist on GitHub to allow me to quickly and easily copy the code into my projects.

Data Flow Diagrams

When we first started doing Data Flow Diagrams at the start of the semester I thought they were the worst thing in the world. However, as I came to understand them more and start to think about more real-world business problems that I was encountering such as creating a website for my Dad or as a side project for one of the many ideas I have I began to realize their necessity.

The scope of the aforementioned projects is large. Too large for me to remember in detail what goes where and what everything is supposed to do. When you create a Data Flow Diagram it lays things out in a clear and structured way that you can refer to throughout the design and implementation process. This makes sure that no features are lost or forgotten about and every process is connected with a reason. This means you aren’t spending time on things that in the end won’t matter to the final product.

Here is an example Data Flow Diagram for Solent’s Portal that I created for my assessment in this unit.

Firebase

During our Web Technologies practical lessons, we have to follow a set of instructions to create a website or simple script. The lecturer has hosted the notes for the unit on Firebase.

I’d looked into Firebase before but couldn’t understand how to use it. However, when an extended task came up in lesson I gave it another go.

I managed to create a simple chat application and clone the notes from the lesson.

Feeling confident I then decided to have a go at some other JavaScript based things which you can read about in this blog post.

As I had already experimented with Firebase I wanted to host my final assessment on the platform. You can see the end result here.

Angular, React, Vue, Node

Whilst working on various projects this semester I’ve encountered the following technologies: Angular, React, Vue, and Node. I’ve experimented with them to some extent and found Node Package Manager quite useful.

Initially, when I first heard about them I thought they were JavaScript Libraries like JQuery, however, they are far from it. Each technology is designed to build an application for use on the web.

Node you even have to set up as a server from which web pages are served from. This makes it particularly tricky, as most shared hosting packages don’t offer Node, or the ability to install it on the server, however, PHP is widely available and has a lot of support and documentation as it has been around for such a long time.

I think these technologies will come in very useful in the future. For now though, I’m not quite competent enough.

New Laptop, Deployment Manager, NAS and VPN

I’d wanted to buy a new laptop for ages as mine was quite heavy and I wanted to take it to lectures, and store it in my bag but couldn’t. This meant I was looking for something quite light. I also wanted something powerful as I do a lot of media production and web development.

Lenovo Yoga 520

I liked the idea of a 2-in-1 and shopped around a little until coming across the Lenovo Yoga Series which I really liked. I found a Lenovo Yoga 520 on eBay for very cheap and snatched it up.

I’ve had the laptop for a couple of months now and it’s been a great purchase. It’s fast, portable, and holds great charge.

I bought myself a pen to use with it too. Me and my girlfriend are going to create a digital comic to test it out so look out for that in the future.

One downside is that I tried to put another SSD in it, but I ran into the somewhat common windows 10 bug of a 100% active time even when the drive wasn’t doing anything. So I ultimately removed the drive and put it in my old laptop where it worked fine before selling it.

Deployment Manager

Seeing as I was going to be using my laptop a lot and I wanted to run the same programs as my PC I looked into deployment managers to keep them synced. However, this seemed like more effort than it was worth so I scrapped the idea.

NAS and VPN

I am, however, going to set up a NAS over the summer so that I can access my vast array of photos from anywhere. This has been something I’ve wanted to do for a long time, but I’ve never had the technical skill, or the willpower to do so.

Now that I am at university and have multiple devices that need to access the same data it seems like the perfect time to implement such a thing.

I got a very decent router; the Asus RT-AC68U for free on Freecycle last year which has the capacity to run a VPN and even lets you access a drive over the internet.

I’ve already set the VPN up which works quite well and will add an extra layer of security to my network when accessing the NAS from university next year.

One drive wouldn’t be quite enough for the type of storage capacity I need so I’m looking to pick up a cheap second-hand PC this summer and turn it into a NAS with around 10TB of storage. Additionally, it will allow more processing power to go towards serving the data and again make it more secure as extra steps can be taken to secure the data on the one machine as that is it’s only function.