Fifth week of #100DaysOfCode – Vue & Node.js

This was the week where I knew I don’t know Javascript.

What do I mean with that “I don’t know Javascript?” It’s a play on words with the “You don’t know Javascript” ebooks, about how I thought I knew JS but after digging deeper I realised that I(we?) know less than we think.

As most people, I used a pre-ES6 Javascript, with some ES6 features (as arrow functions. Even using map, filter and reduce functions!). I thought JS as a “half language” when compared to Python, C# or Java.

Not trying to say anything about people that main JS as their main language, but the only use I had for JS was to manipulating the DOM and maybe doing animations, and nothing more.

That was until I and learnt about Set, Map, WeakSet, WeakMap, Symbols, the Object class, Destructuring, etc (Thanks to javascript.info)

I’m understanding Javascript at a lower level and I see how ES6 and post-ES6 updates are making the language more OOP oriented than it used to be. And I like that.

Resultat d'imatges de learning Javascript

Why I’m doing that?

Despite learning Vue.js right now, I feel I need to learn its language. Yes, I can use Vue.js barely knowing good Javascript practices but there is a line between “Using a language” and “Understanding a language”. And I want to to the later.

As I want to become a professional programmer (instead of being just a programmer), I want to learn all the stuff behind a language or a framework in order to decide what and why use this or that.

So, what I did this week?

  • I learnt how to perform tests with Mocha in Javascript
  • Learnt Javascript low-level stuff such as Object class, Symbols, garbage collector, etc
  • Create a small app with one component
  • Splitting that small app into many components
  • Passing information between components via props/$emit, then eventBus, then Vuex
Mocha Javascript testing tool

Next week game-plan?

Learning more about Vuex, then stop using any Vue tutorial to start creating my own apps. I don’t know how I will manage to code them but that’s the only way to learn, so I’m willing to do it!

Now, my sixth Week of 100 Days of Code

Edit: I finished the challenge, here’s what I’ve learnt: #100DaysOfCode learning Vue: My Five Ws