Becoming More Proficient on the Back-End (Part 1)

Joe Previte
Joe PreviteMonday, July 29, 2019
a notepad with the word goal written on it

Here at Echobind, one of the awesome benefits every employee has is 8 hours per week of “Investment Time.” As you can guess, this time allocated to invest in yourself however you see fit. We try our best to use them to level up our skills or work on side projects that may benefit you or the company in some way.

Q3 — Result Goal

For this quarter, I set the following goal:

Become more proficient in Back-End Development, measured by : shipping 3 features on the API/Back-End side

At my previous job, I spent all my time working on the front-end. However here at Echobind, we have the opportunity to work the full-stack so it’s given me the ability to use Node, TypeScript, GraphQL, Postgres and TypeORM as part of the back-end stack.

My intention behind setting this goal is to fully invest into that side of the stack and level up as a developer.

Q3 — Progress Goals

We take our “Result Goal” and break it down into smaller, measurable goals. For mine, that looks like the following:

A few friends recommended the TypeScript back-end course on Udemy. I chose it because the stack is very similar to the current stack we’re working with (Node, TypeScript, TypeORM, Postgres). Although it uses Nest.js and we’re using Apollo Server/GraphQL, I plan to try building a GraphQL API with Nest after completion of my courses.

The SQL Fundamentals course is meant to help me with Postgres and to give me a solid SQL foundation.

The last is to document my learnings, which I intend on doing once a week in this series of blog posts here on the Echobind blog.

Each post will have the following format:

  • Progress Update — what have I accomplished?
  • Key Learnings — quick recap of major concepts and terms I’ve learned during that week
  • Challenges — things that were difficult or that I had to spend more time learning

And with that, I’ll transition to my first update!

Progress Update

During the week of July 15th, my goal was to complete the following:

  • Modern TS Course — REST API — Task Management Application (CRUD) — 2 hours

Completed Goal

Due to the nature of our current project, I did not have as much time as I had anticipated to dedicate to investment time. I had some features I wanted to finish up so I spent less investment time taking the course.

🤔 What did I do?

Even though I didn’t finish that section of the course, I finished 10/21 modules so almost 50%. My plan is to finish up the rest this week and continue moving along.

💡 Key Learnings

Even though I’ve built REST APIs before, Nest.js introduced a lot of new concepts to me, including the following:

  • controllers

To help myself understand this, I thought of the following example: let’s say you have a team of people in an office. Imagine one person is the Security Guard and the other person is the Office Manager. The Security Guard chooses who comes in and goes out of the office. If you don’t have the proper credentials, you are not allowed in. This person’s main responsibility is “authorization” (i.e. an AuthController). The Office Manager is in charge of tasks. So if it’s related to creating, reading, updating or deleting tasks, s/he is in control.

  • services

Admittedly, I am still a bit confused on this one, but from my understanding, the service actually does the thing. So thinking back to our example, maybe the Office Manager utilizes a service (let’s say TaskRabbit) that goes and gets the tasks for them when they want to read all the tasks. It’s important to remember the Controller is leveraging the Service in order to accomplish this. The Service is where the logic is done, but the Controller has access to that Service, meaning it can utilize it. I hope that makes sense.

  • dependency injection

This is another concept I am still exploring, but from what I learned, it’s injecting dependencies into something else. Let’s say I have a class/module that relies on X dependency. I can use dependency injection to provide that class/module with the necessary dependencies.For now this is the extent of my knowledge, but I hope to provide further examples down the road.

❗️ Challenges

Some things that were difficult for me and that I’m still wrapping my head around.

  • providers

After going 50% through the REST API section, I still don’t quite understand what provider is in the terms of Nest.js. One of my awesome coworkers, Mike, explained that in general, providers are used for dependency injection so hopefully once I read more, I’ll be able to see how the two work without someone else explaining it to me.

  • decorators

Honestly, I don’t think I knew these existed in JavaScript. Actually, at the time of this writing, they are at Stage 2 in the ECMAScript Proposals. Technically, I guess they’re can only be used if you have a transpiler like Babel or if you’re using TypeScript. Either way, I am still learning.

From the basic research I did, it’s described as “a design pattern when you want to dynamically add properties to an object/class”.

That’s all for my update! Thanks for reading and catch ya next week! 👋

Share this post


Related Posts:

Interested in working with us?

Give us some details about your project, and our team will be in touch with how we can help.

Get in Touch