Java Flips Scripts

Travis Gandy
3 min readApr 26, 2021

My first time working with java script was interesting, to say the least. I started this section facing the 3 headed variable hydra(var, let, const). Kill the hoisting head! Then I went on to learning about the DOM, one of those magical Javascript objects that you should really listen to. It acts as the representation of the HTML, CSS and JavaScript the browser will load. I tasted the “syntactic sugar” ES6 Syntax and it was sweet. I discovered what the “source of truth” was(document), it really all sounds like an adventure quest but I promise you I was sitting down the whole time.

The way functions are set up and used in Javascript are way more fun to me for some reason. I think it has to do with how actually writing “function” is so optional from using variables to using arrow functions. How the scope of everything seems to string together so seamlessly makes it feel like I’ve been doing this for a long time. You can literally figure out a way to refactor the same line of code 8 ways to Sunday if you can get with this. When I say get with this I really mean “this”, the keyword that is the context of the property that owns the currently existing code. Using this in a class constructor is probably my new favorite thing. Using the render json feature is a close runner up especially after I implemented a serializer. I had trouble with understanding closures for a while mainly because I had trained myself and honed my skills at killing the hoisting head of the hydra(var) so much that I didn’t like seeing it grow back this far along. Recently though, someone explained it to me as simply “hoisting a nest(nested function) back up a tree” and it was so random that I can’t forget it.

Now let’s talk about CSS. I love that stuff. I used bootstrap on my project and that took me back. I’m talking back to MySpace and MyYearbook and Bebo days. Finding templates and image views for your profile page and copying the url code and embedding it in your display( index.js now that I’m grown). Being amazed at the style, gaining the popularity and followers, I truly thank CSS for the nostalgia because that used to be the one of the best parts of having a social media back then. We were all mini junior front end programmers at some point I guess. The new HTML tricks that come with CSS are a dream to work with also. The “style” attribute on HTML tags and the way you can link multiple commands inside the style and class attributes to manipulate the code displayed within the tags is the coolest thing. Seeing the transition of my basic API being rendered so beautifully in so short a time really gave me new hope and life energy for my future of building applications. I’m not ready to commit or quit either way as far as front end or back end development yet though. They both have great things and nervous breakdown inducing qualities about them but I think I’m shaping out the be the healthy balance guy who tries to do it all and master a bit of both in my own super comfy way.

--

--