w9d4
Almost done!!
Today's Document
2025 on Tumblr: Trends That Defined the Year
Game of Thrones Daily
d e v o n

No title available
Peter Solarz
Xuebing Du

izzy's playlists!
occasionally subtle

★

No title available
"I'm Dorothy Gale from Kansas"
sheepfilms
he wasn't even looking at me and he found me
taylor price

titsay

shark vs the universe
cherry valley forever
art blog(derogatory)
trying on a metaphor
seen from T1
seen from Malaysia
seen from France
seen from United States
seen from Bulgaria
seen from Thailand
seen from China
seen from United States

seen from Canada

seen from United States

seen from Macao SAR China
seen from United States

seen from United States
seen from Hungary

seen from Malaysia

seen from United States

seen from United States
seen from T1

seen from United States

seen from Malaysia
@therealyoshi12
w9d4
Almost done!!
w7d5
What we did:
Full Project from start to finish. Today was the first time we put everything we learned from the past 7 weeks into a final spec’d out assignment. Assignment was to create “BenchBnb” an Airbnb clone for bench’s within the city.
The assignment showed us how to use the google maps api, which is pretty amazing! Basically learned how to place markers on a map that you place on the page. Everytime we dragged the map somewhere else, the markers would refresh based on the location of the page! Awesome!
The one thing i noticed about the assignment was that it was extremely react intensive. About 80% of it was dealing with the complexities of the React framework. Which is cool since it’s such an up and coming portion of front-end developement, yet at the same time we spent a lot of time on other portions of web development as well.
Tomorrow we’ll be working on the 2nd half of Benchbnb, and then it’s off to start our final projects!
I chose www.giphy.com as mine.
Topics where I struggled:
The struggle was really remembering all the different methods we learned. For example when we were setting up the rails model, I almost forgot how to type in ruby since we had been javascript intensive for so long! I don’t understand how people learn so many different languages.
Felt a lot more improved:
Well I have an idea of the big picture of web development now so that’s a plus.
How I’m feeling:
Big relief that testing is done for now, but a new nervousness is creeping up. Usually for assignments we have guidelines which direct us toward creating the project. For final projects, all that gets taken away. Training wheels are off.
8/10 motivation
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy
w7d4
What we did:
React-based Pokedex. Today’s assignment was creating a react /flux app with all the react paradigms we learned from the past couple of days. The only twist was the inclusion of nested routes within react.
For the past couple of days we’ve only been manipulating objects within a one-page state. Therefore, once you loaded your HTML elements, you were manipulating elements within the page but not refreshing the whole page. A piano app that’s loaded on the index page is a good example. We were manipulating the keys of the piano (list elements) but not refreshing to another page.
What if you wanted to move on over to another page without making a call to the server? This is where react routing comes in. React gives you the ability to stay within one request/response cycle but still switch to another page! This might be true for other front-end frameworks but it’s REALLY fast since you don’t have to load all the HTML elements again by making a request to the server.
On a separate note, there’s no assessment next week, therefore we all passed! Now we can finally focus on our final projects and then go straight into job search mode.
How I’m feeling:
Amazing! Now all we have to focus on is our final project.
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy
w7d3
What we did:
React / Flux music player. Today we really got to understand firsthand the architectural foundation behind Flux and React by building a organ player in the browser. We were given a set of music notes with a different range of frequencies, linked up a note-playing API and then directed our application to play those notes based on which key we pressed.
This new Flux way or (in latin: flow), utilizes a one-direction state-control therefore making it easier and faster for developers to identify a bug in the code and also the state does not have to traverse through multiple models to refresh it’s data. Here’s how I learned about it in the context of the piano keys.
- The page is loaded and the browser is waiting for some input to occur.
- User hits a key
- Page listeners hear about this new input and then immediately routes it to the action controller, which attaches a type of action to the input and then routes it to the dispatcher.
- The dispatcher (which lives in the store!) determines whether it is a legitimate action and then calls a method in the store to add it to it’s array of inputs.
- The store emits a change event notifying all parts in the application that the state has changed.
- In react (the view) constantly listens for a change in the store. Since the store emitted a change, it processes it’s current state and then calls a method based on the current state.
- React re-renders based on the current state and the cycle is started over again.
So how does this translate to pressing a key and emitting a sound?
- User hit’s key “f”
- Page hears that the key “f” has been hit and routes to the action controller.
- Action controller adds a “create note” action along with the key “f” routes to dispatcher to which attaches an action to the dispatcher
- Store receives request from dispatcher with both action “create note” and key “f”
- Store adds key “f” into it’s array and also notifies that there is a change in the state in the system
- the view is notified of a change in the state, looks at it’s current state and sees if the key “f” has been pressed by matching iwth the array of store keys. Since there is a match, it calls _playNote which emits the sound by translating the “f” to a frequency
- This ends one complete flow of Flux.
- When the finger is lifted off of key “f”, it notifies another change in the state of the store, therefore emptying the store of the key “f” as well as a change in the state.
- The view is notified and then compares it’s current state to the store array and realizes “f” is no longer there, therefore it calls the end_note method which stops the sound.
The hardest and most confusing part about this framework was to wrap my mind around the fact that all of this can happen in milliseconds! I would literally hit a key the sound would emit and then when I took my finger off the key it didn’t emit at all! I’m a very visual person and this was not visualizing in my head.
Topics where I struggled:
React and Flux in general are just hard concepts to grasp since there are a lot of moving parts. Again, I don’t know what the other front-end frameworks are like, so I’m finding it having a hard time understanding how it’s better.
Felt a lot more improved:
React/Flux. I have a clearer understanding of what’s going on under the hood now.
Code that == Mind Blown!
All that code in the changehandler is pretty amazing in the store. I honestly don’t know how some of these guys come up with this stuff.
How I’m feeling:
I missed morning lecture today since I was sick, but was able to make it to class after. I’m still feeling sick, but I was glad I was able to do this project since it’s fundamental for react/flux.
7/10 motivation
Code Music
The beeping sounds of the computer made piano soothed my ears today.
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy
w7d2
What we did:
Full rails integration with React. Our job today was to create a fully integrated site with a rails backend and a react-powered front-end. It was our first full experience using both “rails new todo-app” and “reach.createClass” on the same day! Groundbreaking stuff.
Switching back to ruby after a couple weeks was a weird experience. No “;” after every single line, no declaration of variables! What was this world coming to? I’m glad I retained some of my ruby knowledge and haven’t completely put it to waste.
The project for today consisted of creating a todo-list app with a react front-end. Sadly, the setup with .ajax calls and rails back-end was hard enough hurdle that me and my partner were not able to get to the actual react portion. I would like to finish this project up soon, since it’s one of the first projects where we get full integration but at the same time we have a mega-ton of reading on Flux tonight.
Which reminds me, shout out to Matt for uncovering this beautiful gem of a pun during lecture today:
-TA: “yeah... since React is a relatively new subject, we’re still trying to decide what stays on the curriculum and what doesn’t”
-Matt: “So you’re saying the program’s in.... Flux?”
You’re gonna be a great dad Matt.
And finally, they sent out more details about our final project we’re supposed to show off to potential employers. What do you think? More functionality or more flashy?
Topics where I struggled:
Integration with .ajax and react was a bit of a struggle today. We’re so used to having controllers which render to actual pages in rails that it was hard for me to fathom the controllers just passing Json objects to the “Javascriptified-front-end” to handle most of the legwork of the view. Once we got this down, felt like it would be a bit easier.
Felt a lot more improved:
I’m glad I still retained knowledge of rails and ruby. I may have forgotten some of the finer points of the syntax but still understand the basic concepts. Also I’m starting to like Javascript a lot more.
Code that == Mind Blown!
React.createClass{}. As far as I know, React.createClass and react.render are the core building blocks which allow you to break up your front end code into sizeable chunks. Facebook’s new... framework? allows for easier and faster front-end development with their new “language”.
How I’m feeling:
I’m still either recovering from sickness or about to get even sicker. I have no clue. But pho for sure tonight.
7/10 motivation.
Code Music
The sound of silence has actually been a nice change. You know... the clatter of the keyboard or the occassional siren from Market st.
Interesting Sidenote
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy
w7d1
What we did:
React.js. React is one of those exciting new things you hear about that you never really understand. We’re the first new group from App Academy that’s learning this stuff and we’re not learning the apparently tedious backbone framework.
It’s really tough to gauge how much more convenient React is from other front-end frameworks, since I really don’t have experience with any other front-end frameworks. However, from what I learned today it makes it seem like there’s a backend on the front-end. From my limited knowledge of css and HTML it seems like whenever a front-end developer wanted to change something on the client side, they would have to manually go into the view and then go through the code piece by piece to remove specific elements.
Through our exercises today, React provides a framework that allows the front-end developer to make mass changes on the front while also shortening the amount of code necessary to make those changes. Nice!
In addition, it seems INCREDIBLY fast. It’s more expensive (slow) to load each DOM (html/css element) rather than run some javascript to output the HTML/CSS. From a design perspective, it seems incredibly clean as well.
Anyways, we have to think of final projects in the coming week. Anyone have any ideas?
Topics where I struggled:
The syntax is not too bad, nor is the logic, but we are working with a javascript-like language for React called JSX.
How I’m feeling:
I may be coming down with a cold so I didn’t feel too good today. Also felt like my mind has been in a haze all day. Getting that chicken soup after.
5/10 motivation.
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy
w6d5
What we did:
Passed the 5th assessment! Barely, and I’m talking about ... barely. Which means I’m 99% sure I’ll pass through a/A. There are 6 assessments, if you fail 2 then you get kicked out of the program. Therefore, unless I have a catastrophic 6th assessment (where I fail and then proceed to fail the retake), I should move on to the final project and jobs curriculum of the program. There might be some with 1 failed test in our group so far, but I’m 100% confident everyone in the group right now will pass on to the final project and job curriculum stage as well.
Onto the final bits of jQuery. One such great functionality of jQuery is the ability to significantly simplify and shorten ajax calls. What is ajax? You know when you type in a google search bar and it autocompletes your search question or sometimes even pops up some of the results as you type? That’s ajax.
Short for Asynchronous Javascript And XML, it’s really a method to load bits and pieces of a webpage rather than having to load the whole page itself. In the olden days of the internet (pre 2004?), pages were loaded and reloaded in its entirety whenever an action was performed. So in those days if you “like” a status the whole page would refresh and then you’d see that the event that you “liked” had your like. Imagine if you were to comment on a facebook status today and you had to reload the entire page just to see the status comment section updated. How barbaric.
With ajax, users can update certain sections of pages without having to reload the entire page, allowing for a more seamless and streamlined user experience. I won’t go into too much detail about how it works (because I’m too sure myself) but I will say that it’s almost like having a mini-window within the page which continuously updates with a bit of javascript.
The earliest instance of ajax, that I remember was the announcement of google wave which was google’s project on instantaneous chat. The demo shows how one user can see what the other user was typing in real time. And then the search bar autocomplete came as well and I remember being a bit wow’ed by that as well.
All in all, ajax is an awesome bit of functionality to have on your website primarily because its fast and seamless for the user.
Now onto react.js, the hot new darling of front-end development that we will be immersed in this week. Exciting to learn but I will leave with this quote from Ned: “Beware of the cutting edge, it can cut you.”
Topics where I struggled:
Test taking has become an issue that’s really hard to ignore. I prepped just as much as everyone this week and I definitely had a below average score (although passing) for the assessment.
Felt a lot more improved:
I’m just glad I 99% passed into the jobs curriculum.
Code that == Mind Blown!
$.ajax{
url: “/users”
data: data,
datatype: ‘json’,
success: function(){
console.log(”hi”);
}
}
This is the request / response mainly for ajax. Awesome!
How I’m feeling:
Did nothing code related yesterday for the first time in a long time. Now it’s onto react.
7/10 motivation
Code Music
This was stuck in my head this morning so... here you go:
https://soundcloud.com/universalrepublic/kiesza-hideaway-radio-edit
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy
w6d4
What we did:
Today we tried to implement this: http://appacademy.github.io/jQueryPlugins/html/carousel.html
From the looks of it, it looks like a relatively easy project to do, however in order to make it look pretty there’s actually a lot going on in the backend and browser.
First there’s the positioning of the pictures to make sure they fit within the frame of its container. If the picture is slightly larger than the container that holds it, the picture will pop out of its frame and all over the place on the browser!
Second, the smooth sliding transition you see of the cat picture actually requires some work to implement. If this were done hastily pictures without a transition would appear out of nowhere and disappear just as quickly when replacing its counterpart. However with a transition, one must think about a mix of javascript, css and the order at the most precise level. For example, one must consider the end of the transition period when the picture goes out and then time it with when the picture goes in. Of course javacsript and jquery has methods to help you time these functions, but in order to have to take these into account requires a lot of broad and complex thinking.
And finally the last layer was ability to go backwards or forwards which means twice the complexity in terms of logic.
I thought front-end was easy! Now I’ve come to understand that’s not the case. Still want to implement parallax scrolling though.
Topics where I struggled:
The order of when to call the various methods for Jquery tripped up our project a couple of times. A relatively new element that was introduced (callbacks, setTimeout, setInterval) tripped me up a couple of times since we thought we had parsed our code fully but then when we were debugging found that some functions were called in an asynchronous order.
Felt a lot more improved:
Debugging. I’m mainly starting to like javascript purely for its practicality with Chrome Dev Tools. The fact that you’re able to debug your code within browser is simply amazing!
Code that == Mind Blown!
Currying
No, this is not your favorite indian dish or a basketball move, this is teh concept of calling a function in separate instances until it fulfills a certain number of arguments. Traditionally a sum funciton is written like this:
sum(arg1, arg2, arg3){
return arg1 + arg2 + arg3;
}
But with currying you can call a function like this:
var sum = curriedSum(3);
var sum1 = sum(4);
var sum2 = sum1(20);
sum2(30) => 54;
You don’t have to give all your arguments to the function all at once. So why is this useful? Perhaps you’re a developer for a grocery store and they want you to build a calculator? Currying can help you show the incremental sum as you add items to your checkout and then show you the final total at the end.
How I’m feeling:
Surprisingly excited to get this 5th assessment over with. Lots of different topics to study tonight:
7/10 motivation
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy
w6d3
What we did:
JQuery. Some of the features that really wow you when you a visit a website, flashy pop-ups, disappearing fields, data that comes by without reloading the page is mainly powered by front-end javascript. Since javascript is sometimes extremely tedious to write (especially with HTML mixed in) a Javascript library called JQuery is used to ease the stress on a developers fingers.
JQuery allows the (easier) referencing of the many HTML & CSS elements on the page and allows for easier access to do cool stuff like transitions, fades, and AJAX requests. You know front-endy design-y stuff that really makes your website look good.
Today’s projects were to make the UI’s of three games: Towers of Hanoi, Tic Tac Toe and Snake. While in weeks past we were working primarily on the logic, this time we were given a skeleton back-end which handled the logic and instructed to make a fully useable UI interface.
That includes alerts when a invalid move was made, Transitions when games were won and potential move highlights. It really feels like the studying has come full circle since we worked on the logic in the beginning and now we’re designing the front-end with the end goal of making a fully functioning, beautiful website. Excited to see what the next weeks bring!
Topics where I struggled:
Still struggling with game logic. Today we tried to implement Snake and it was just too much to have to think through when initiating the game. Also realized I can’t code when I haven’t slept a lot.
Felt a lot more improved:
Javascript. We blazed through some of the jQuery front-end portions.
How I’m feeling:
Sleepy. Must get some sleep.
4/10 Motivation.
Code Music
Haven’t really been updating this, but I like this Greek DJ a lot! Can only find him on mixcloud. Might be a repost.
https://www.mixcloud.com/thanassipsarras/after-summer-2012/
Interesting Sidenote
I can’t believe it’s October already. Feels like it has been the longest shortest month ever. I also can’t believe I’ll potentially be looking for jobs in a few short weeks and creating a capstone project. Any ideas anyone?
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy
w6d2
What we did:
CAT CSS. We created a facebook for cats ( I think a/A is obsessed with cats) without all the functionality of facebook. That meant starting from a blank html page and adding the css and HTML elements one by one.
We’ve done some complicated stuff over the past couple of weeks with algorithms, frameworks and data structures, but CSS was just downright tedious! There’s potential to screw up a lot of things if you don’t know what you’re doing (well which is the case for many things).
We started with a simple header bar with three links. One link had a dropdown menu upon hover which was hard to implement but interesting to learn about.
Next we moved onto the content header section and content section. Making the content fit within the page and making sure they were within their borders was a challenging as well.
And finally by the end of the day we created a picture and profile sidebar section. Hopefully I can start putting up some of these projects up soon!
Topics where I struggled:
Floats and position:relative vs. position:absolute. Some of these took an hour to debug.
Felt a lot more improved:
Javascript. I don’t necessarily feel ready to take the assessment yet, but I’ll get there.
How I’m feeling:
Feels like I’ve been burning the candle on both ends for quite a while now. And I understand there will not be a end soon.
6/10 Motivation
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy
w6d1
What we did:
Asteroids. Today was our first foray into creating a browser based game and we started with the iconic 80′s arcade game asteroids. For those that were not born in the 80′s or before... here you go: http://www.freeasteroids.org/
The great thing about Javascript and what sets itself apart from Ruby is the fact that you can immediately test your code on your browser without having to push to a server or do all this ridiculous prep work. You can change your code and then check on your browser.
So back to creating asteroids. I’ve never really been much of a gamer, except for a instances in middle school where I was hooked on Goldeneye (who wasn’t?) and a quarter in college where I literally played starcraft every single day. BUT, being on the end where creating a simple game like Asteroid makes me respect what some of these game devs go through and have to think about!
This was none more evident than when we created our asteroids. As you develop the game, here are some of the things we had to think about:
- size of the asteroid (in our case a circle)
- the velocity of the asteroid
- Whether it would collide and how to calculate that
- How to wrap the asteroids back onto the screen when it goes off the canvas.
The biggest realization I had as of today was that when you’re displaying a game, you’re actually displaying 20 millisecond (well depends on computing power) snapshots of each frame. So what looks like a moving object on your screen is just each snapshot of that instance computed REALLY quickly. Take for example a moving object. It starts at pixel (1, 1). If it’s moving the next snapshot will show it at (2,2) and then (3,3) and so on.
Wrapping the asteroid to come back onto the screen also took a lot of math that I haven’t used in a while... must brush off those rusty skills.
On top of that, I was learning Javascript syntax as we went along with the project!
Hopefully I’ll finish this up soon and host it on a server for a playable online version.
Topics where I struggled:
I have no used my high school math more than I have at any point. We totally busted out the use of Pythagorean theorem today: x2 + y2 = z2. The sum of two squares equals the square of the distance.
Felt a lot more improved:
Javascript inheritance and scope. Just when I was getting comfortable with how Ruby flowed and inherited from other classes, I feel like I’m starting at square one (which I am) with Javascript. It’s not necessarily harder than Ruby, it’s just a different syntax. I would imagine its the difference between Chinese and Japanese (similar but different?) Slowly but surely I’m understanding more.
Code that == Mind Blown!
Javascript:
setInterval(callback, time increments);
This piece of code makes it possible to create the display of games. It’s basically a function that repeats a function (in this case the callback) for x amount of time increments. This is central to the asynchronous nature of Javascript as well as rendering the game.
How I’m feeling:
I took a mini break from studying this weekend but it was exactly what I needed. Have an assessment on Friday so there’s not much room for rest. On a separate note, I can’t believe it’s week 6 already, should I start looking at potential industries I’m interested in?
7/10 motivation
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy
w5d5
What we did:
Another day of Javascript exercises. Today we learned basically how to translate some of the things we did in Ruby to Javascript. It was kind of like rewriting our projects from Ruby into Javascript and boy... were we spoiled.
Some of the funny things I noticed from my translation from Ruby to Javascript:
When you push into an array in Ruby, the return value (as it’s clearly most logical) is the array with the new value pushed in to the back:
[1,2,3] << 4 returns:
=> [1,2,3,4] Makes sense?
With javascript:
[1,2,3].push(4);
=> 4 ??? Returns the new size of the array. Does not compute.
The fact that a lot of objects are instantiated via function(){} trips me up a little bit as well.
Considering this language was created in a mere 10 days (https://en.wikipedia.org/wiki/Brendan_Eich), it’s amazing how it’s the number 1 web language in the world.
But! I understand javascript can do lots of cool front-end design like parallax scrolling ( https://en.wikipedia.org/wiki/Parallax_scrolling), which I’m really interested in integrating into a project that I’ll do later on. Here’s some of the best parallax scrolling sites I’ve encountered:
- www.onlycoin.com
- http://www.artofflightmovie.com/
These sites are just so beautiful, makes me want to cry.
Topics where I struggled:
Some of the syntax is just really weird. Doing the algorithms + new syntax is not fun.
Felt a lot more improved:
Javascript? But i’ll be studying all weekend...
How I’m feeling:
I’m so glad it’s the weekend. I’m able to catch up on some projects I missed over the week:
7/10 motivation
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy
w5d4
What we did:
Javascript. THE language of the web. Traditionally it was a front-end language, i.e. the stuff you see on your browser but now there are several frameworks (node.js) where one can develop a full website with just javascript.
Coming from a syntax perspective, it’s slightly more tedious, it’s like taking off the training wheels after going from Ruby. Imagine, having to recreate your own loops every single time if you want to find an element in an array! It’s kind of like having to gather the kindling, chop the wood, set up a pit and fire for cooking instead of turning on the gas stove.
Here are some of the differences I noticed right off the bat:
- A lot more semicolons (;) and usually more prevelant in ever line.
- More tedious, have to make sure to dot your i’s and cross your t’s. For example in order to define a function you might have empty ()’s parenthesis even if the function does not take a parameter. In ruby, this would be left off if the function did not take any methods.
- The better thing about javascript is now it’s phenomenally easier to start coding browser based applications. The chess games we were producing earlier in the course was primarilly on a computer based console called terminal. With javascript we’re now able to create games on the browser, and thus easier to share.
So why would we ever learn Javascript if it’s not as syntactically fluid as Ruby? It basically powers every single page of the web, both on the front-end and back-end side AND it’s faster than other languages. I haven’t learned why yet but I’m sure I will. While there may not be a noticeable difference with small applications, it certainly bubbles up when you are handling lots of traffic and data.
Today was just an intro into javascript as we went over the basics of arrays functions and a little bit of a browser game. This coming week will be a full on immersion of javascript, so look out for more browser based games soon.
Topics where I struggled:
Recursion. We were asked to recreate some of our old projects form ruby-recursion to javascript recursion. I understood the language, I still didn’t understand the concepts... I heard this comes up a lot in interviews so something super important to learn.
Felt a lot more improved:
Javascript... duh.
Code that == Mind Blown!
Here’s a sample of ruby code that counts from 1 to 5:
Ruby:
def count_to_five(n)
n.times { |x| puts x }
end
Here’s the same thing in Javascript (to the extent of my limited knowledge of Javascript).
Javascript
var countToFive = function(n) {
for(var i = 1; i === 5; i++){
console.log(i);
}
}
See a difference? I’m definitely not bashing javascript. Just the differences.
How I’m feeling:
After the monster that was Rails-lite and activerecord lite, it’s nice to be able to work on “easier” concepts like javascript.
8/10 motivation
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy
w5d3
What we did:
Second half of Rails Lite. Like yesterday we continued on the path towards creating the rails framework.
As I mentioned before, rails is a web framework that makes it easier for developers to build and set up a website quickly and efficiently. We covered the database last week through activerecord these past few days focused on the controller and routes.
Whenever you type in “www.google.com” or whatever address you’re looking to go to, your computer goes through these steps in order to get you to where you want to go. The www.google.com is essentially an alias for your ip address which is the precise place that you want to go. In order to get the appropriate ip address your computer executes the following steps once you hit the “Enter” button:
1. Looks through your cache in your browser to see if the address was stored there.
2. If not looks through the massive servers (I believe there are 13) which are house all the domains that have ever been created. While looking through the servers may take a while, it seems they are categorized in a manner that makes it easier for your computer to search for the address
3. Once the address is found, your browser and the receiving server, in this case “google.com” create an open TCP protocol, effectively a handshake. (https://en.wikipedia.org/wiki/Transmission_Control_Protocol)
4. You do your thing on the site and then the connection would either be closed or kept open.
Ok, I gave an extremely generic version of how the internet works, but the project that we worked on for the past couple of days was centered around handling those TCP requests.
Topics where I struggled:
This server stuff is really interesting but really really complex! I was able to power through the assignment today, but I don’t necessarily know if I comprehend it all.
Felt a lot more improved:
My knowledge of how the internet works in general. I knew slight nuances about websockets, but now that we’re going step by step on how it works, it’s really coming full circle.
Code that == Mind Blown!
server = WEBrick::HTTPServer.new(Port: 3000) server.mount_proc('/') do |req, res|
Controller.new(req, res)
end
Apperantly you can create your own server to handle requests with this little snippet of code and with the ‘webrick’ gem.
How I’m feeling:
Still extremely tired. The pace is mind-numbingly fast. Apparently we’re supposed to learn javascript in a week.
3/10 motivation
Interesting Sidenote
I haven’t exercised in a full month. Going to shoot around for a little bit today, release some endorphins
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy
w5d2
What we did:
Assessment 4 passed! 4 down, 2 more to go. If I pass the next one I won’t have to worry about the last one! Today’s rails assessment was surprisingly straightforward and it took me about the half the assessment time it usually takes to finish. I’m usually scrambling towards the end of these assessments but I’m glad I finally didn’t have to feel nervous after taking an assessment.
After the assessment it was immediately onto creating Rails-lite. A two-day solo project, we’re basically creating rails with ruby and learning the inner-workings of rails along the way. In terms of what rails does, everything makes logical sense, but the actual act of implementation is MIND BOGGLING. No wonder DHH is modern day genius (http://david.heinemeierhansson.com/)
I struggled getting the routes and queries down right from the get go. But a full day to work on this tomorrow!
Topics where I struggled:
Params and routes for rails lite. The serializing and deserializing of the hashes always gets me!
Felt a lot more improved:
App Academy. Passing the 4th assessment really gives me 99% confidence I’ll pass the program.
How I’m feeling:
I am so tired. Maybe it has been the constant preparation for tests or the hectic study schedule but today has been one of those days where I can barely lift a finger. Going to take it easy tonight and resume tomorrow
2/10 motivation
Code Music
Music to accompany my dreary mood:
https://soundcloud.com/sea_breeze174/meant-to-be-late-night-alumni?in=the_real_yoshi/sets/late-night-alumni
Interesting Sidenote
I’ve been thinking more about living situation post App Academy. I never thought I’d say this, but I might like living and working in the suburbs a lot more than the city! Who knows what I’ll look for after a/A.
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy
w5d1
What we did:
Integration testing and Capybara. Why is integration testing important? Similar to rspec, it helps the developer do testing on the public facing portions of their website. For example if you were to create a “Comment” functionality for a specific portion of your website, the integration test framework (that you yourself write) will help you ensure that the comment belongs in the right place on the page, and is not accessible by unintended users or modified by anyone else but yourself when you place a comment. This rigid system of test, pass and refactor fits into the whole system of test-driven development.
The concepts themselves were not that hard but the total implementation of tests and then the logic essentially doubles the time it takes for one to put up some logic! In the same token, it ensures that one also puts a less mistaken website as well.
Rails assessment is tomorrow, and supposedly it’s a big cahuna. 2 hour long test and you have to set up a rails app. Will be studying for a while tonight.
Topics where I struggled:
Capybara language. It’s similar to rspec but not entirely. Also creating new instances of users with FactoryGirl and Faker were time consuming but not a mess.
Felt a lot more improved:
Understanding rails in general. Getting a great view of how everything works under the hood.
Code that == Mind Blown!
Faker gem. There’s a ruby gem that creates fake names for you
How I’m feeling:
Anxious. Tomorrow is the big 2-hour rails test. I feel like if I pass this, I can pass a/A for good.
9/10 motivation
10/10 anxiety
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy
w4d5
What we did:
Another full day of rails with an emphasis on polymorphic associations and nested routes. Today we were asked to create a Reddit clone that has posting functionality, comment functionality, subreddit-moderator relationships and login/logout ability. Of course it looks absolutely nothing like reddit but it was pretty interesting getting the basics down.
In addition a good friend from the previous cohort came to visit a/A, went out for an interview and received an offer for a job! Awesome! Seems like that job within 2 months of graduating had some truth behind it.
For now it’s a night of catching up with friends, watching portlandia and then a whole weekend of studying for the 4th (and perhaps hardest) assessment.
Topics where I struggled:
There were a couple parts where in the HTML form to controller transfer I had a tough time on, but it wasn’t really about the logic but more about the complexity of communicating between the view and the controller.
Felt a lot more improved:
Authentication. Was able to set up the authentication portion of rails within 30 minutes of getting the instruction, something that seemed unlikely 3 days ago.
Code that == Mind Blown!
When passing a params hash from the form to the controller it was pretty awesome that arrays are able to be passed into the controller as an array AND objects will be created for each item that’s passed.
params.require(:user).permit(:username, :password, user_id: [ ] )
the “params” is able to the the user_id as an array and then create multiple associations in another table! Rails is truly amazing.
How I’m feeling:
It’s Friday. I’m le tired.
7/10
Interesting Sidenote
My typing speed has increased overall from 89 wpm to 98 wpm in a span of 4 weeks! See if you can beat my score on typeracer.com. Oh yeah I’ve gone over 100 wpm before.
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy