Scope, Hoisting and IIFE’s

It’s the start of the fourth week of my time at TIY! I have gained so much in that time, yet there is still so much ahead. As we enter our second and final week of JavaScript I am feeling like slowly I am gathering all the pieces I need to build amazing things! I can’t help but wish that I was able to put them all together now, and that I had all the pieces to start building a professional portfolio in my spare time, but I will have to accept where I am for now. I find myself wanting to practice more JavaScript in the way of HTML manipulation. I feel that is my biggest area for growth right  now as we only focussed on that for one day last week. I’m hoping I’ll have time to build our hangman game into an actual webpage! I’d love to have it on my portfolio. While I am an extremely efficient and hard working individual, sometimes I am lacking in creativity. I’m hoping that while I finish the course and build my case for a job, that I’ll be able to pull some creative genius from somewhere. I know employers will look for that and I know I can build whatever is set in front of me, it’s just a matter of deciding what to build!

Our lesson for today was heavy on scope and protecting the global scope from repeated variable names. They always say your job as a developer will be 90% coming up with names for things. Our activities today were pretty straight forward. We were given lots of functions with improper use of scope and hoisting and had to restructure them so that they worked in the way they were intended.

IIFE’s are used to compartmentalize all the variable names inside a function that will be “immediately invoked” so that you never have to worry about those variable names interfering with your global variables. These kinds of logic rules just make sense to me. If you have two children you wouldn’t name them both the same thing, ever. So don’t do with with your computer babies aka variables.

I’m still waiting on some info on the crash course Bruin and I are leading next week. I’m really hoping the details come along soon. I HATE being unprepared, but I am very excited about the opportunity!

I had a short meeting with the front-end guy and our campus director and was told that I am exceeding expectations and am not a concern for either of them when it comes to finding a job after the cohort. I hope what they say is true! It’s funny how you can never see yourself the way other see you…

Until tomorrow!

Advertisements

2 thoughts on “Scope, Hoisting and IIFE’s

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s