Skip to content

Instantly share code, notes, and snippets.

View sekharp's full-sized avatar
💭
Stay-At-Home 🐶 Parent

Sekhar Paladugu sekharp

💭
Stay-At-Home 🐶 Parent
View GitHub Profile
@sekharp
sekharp / love.rb
Created October 26, 2015 17:58 — forked from JoshCheek/love.rb
Love.rb
_ \
, __ , # (C) Josh Cheek
*,_ = # 2015
def __ ___ , # Inspiration
*__, **_ # Is
putc ___ # Obviously
end, def _ *_, # Yusuke
**__ # Endoh
_. #
map {|_ ;__ # And

Elm

Learn How to Build Reactive Web Apps Using Elm

There are plenty of JavaScript-based frameworks for building single-page web apps. But the common problem with all of them is… JavaScript. We need a better solution: not just a band-aid over JavaScript's ugly parts, but instead a whole new, fresh approach to browser programming. We need Elm.

Elm apps run in the browser, but you don't write them in JavaScript. Elm embraces the good parts of functional programming, but lets you ignore the theoretical underpinnings. Indeed, Elm makes functional, reactive programming not only possible, but practical and even fun!

In this course, you'll learn Elm from the ground up as we incrementally create a single-page, reactive web app. By building a real project with real code from scratch, you'll see how everything fits together. Along the way you'll discover how Elm helps you write reliable code that stays well-factored and easy to maintain even as you scale feature-rich apps.

Array Prototype Methods

I understand that functions in JavaScript can take any number of arguments. Yes

I can describe the similarity between blocks in Ruby and anonymous functions in JavaScript. Yes

Where are the methods available to all arrays (e.g. forEach, map, etc.) defined? Array.prototype.ethods

JavaScript Functions

I can explain the difference between function declarations and function expressions.

I can explain what the value of this is in a normal function.

I can explain what the value of this is when called from the context of an object.

I can explain how to explicitly set the value of this in a function.

I can explain how the new keyword changes the way a function behaves.

I can explain the implicit steps that happen in my function when I use the new keyword.

I can explain the difference between an object's prototype and the prototype property on the constructor function.

I understand how to place method on a prototype.

I understand the difference between using Object.create and using a

**Step One**: Watch [Sorting Algorithms in JavaScript](https://www.youtube.com/watch?v=uRyqlhjXYQI)
**Step Two**: Fork this gist.
**Step Three**: Respond to this question in your fork: "What are some of the balances and trade offs between different sorting algoritms?"
-It all depends on what type of data you're sorting and whether you're trying to optimize for use of memory/computing power
-Bubble sort is useful to study but generally not useful in real world application. They're slow and take a lot of memory
-Insertion sorts are better in that they're more stable, but for application on large datasets are still bad
-Merge sort is all around the best, but highly data intensive. Definitely the best option with a lot of computing power.
@sekharp
sekharp / require.markdown
Last active February 16, 2016 22:13 — forked from rrgayhart/require.markdown
The Concept of Require

When you start working with WebPack for GameTime, you'll notice that you can't just define a variable in one file and find it in another as easily as you can in Rails.

Read Node.js, Require and Exports and Organize Your Code with RequireJS

Fork this gist and answer the following questions:

  • In the context of Node, what is a module? A module is the fundamental building block of node which maps directly to a file. A module can be a container of exported values or not.

Step One: Watch Writing Testable JavaScript - Rebecca Murphey from Full Frontal 2012 (award for worst conference name ever?)

Step Two: Fork this gist.

Step Three: Consider the four responsibilities that Rebecca lists for client side code (hint: they're color coded).

Did any of the responsibilities that she lists surprise you?

  • It's helpful for me to see what Rebecca lists here as best practices. I'm new to JavaScript and hearing what experienced developers see as important rules to follow gives me structure. None of them surprised me per se. It did take me a little while to understand "Application State."
// aka root component
var Dashboard = React.createClass({
getInitialState: function() {
return { headerIsActive: false }
},
onButtonClick: function() {
console.log('in DASHBOARD!!');
},