Koren Leslie Cohen

  • About
  • Blog
  • Contact

3 comments

JavaScript

JavaScript Variables: Declaration, Initialization, Hoisting & Closures

August 21, 2014 by Koren Leslie Cohen

preloader

Closures are inner functions that have access to the outer function’s variables, also known as a scope chain. Included in a closure’s scope chain are the closure’s own variables, the outer function’s variables, and any global variables. The inner function also has access to the outer functions parameters.

33 comments

Ruby / Rails

Creating a Simple Search in Rails 4

July 20, 2014 by Koren Leslie Cohen

rails

If you have a blog and you want the user to be able to search your posts, you will need to add methods to both your posts controller and post model, and create a corresponding search form.

1 comment

Ruby / Rails

Adding a Static Page to a Rails Application

July 20, 2014 by Koren Leslie Cohen

preloader

Adding a new static page to an existing Rails application can be accomplished in a few easy steps: (1) create a static controller, (2) generate static views, and (3) create corresponding routes.

31 comments

Ruby / Rails

Rails: Generate Model vs. Resource vs. Scaffold

July 15, 2014 by Koren Leslie Cohen

front end engineer interview questions

If you’re just learning Ruby on Rails, you may be confused as to when to generate individual models, resources or scaffolding, and what files are created by each command.

6 comments

Ruby / Rails, Tutorials

Rails Tutorial: Getting Started with Ruby on Rails

July 14, 2014 by Koren Leslie Cohen

javascript array methods

Rails is a web application framework written in Ruby, also known as an MVC, or Model View Controller.  Rails has two major philosophies: (1) DRY (“Don’t Repeat Yourself”) and (2) Convention Over Configuration, meaning Rails has a right and wrong way of doing things, and if you follow the Rails way, you shouldn’t have to… Read More

1 comment

Ruby / Rails

The Importance of Web Application Security

July 9, 2014 by Koren Leslie Cohen

preloader

Last week, I deployed my first web applications, a big moment in any developer’s life.  One app, a guestbook for my friend’s wedding, was written in Ruby, dependent on the Sinatra gem  and deployed through Heroku.  It consisted of a simple form where friends and family could leave messages for the happy couple. I excitedly… Read More

0 comments

Ruby / Rails, TDD, Tutorials

A Beginner’s Guide To RSpec

June 24, 2014 by Koren Leslie Cohen

devise redirects

RSpec is a behavior-driven testing tool for the Ruby language.  RSpec is used in test driven development (“TDD”), where the developer writes the test based on what s/he hopes the program will accomplish, and then creates the program to accomplish the goals of the test. While this would seem to create additional work for the… Read More

11 comments

Ruby / Rails

Nested Arrays, Hashes & Loops in Ruby

June 9, 2014 by Koren Leslie Cohen

devise redirects

Arrays and hashes are common data types used to store information.  The main difference between an array and a hash is the manner in which data is stored.  Arrays, represented by square brackets, contain elements which are indexed beginning at 0.  So if an array contained three elements, the indexes for those elements would be… Read More

0 comments

Git, GitHub

Git Branching

June 3, 2014 by Koren Leslie Cohen

setup git

Branches are copies of a repository where you can create changes without modifying the parent or master file. Branching is useful for experimental changes, fixing bugs and changes you aren’t sure you want to commit yet. Branching is especially useful when working on a project with multiple developers.

0 comments

SQL

SQL Cheat Sheet

May 31, 2014 by Koren Leslie Cohen

web developer

SQL is used to create databases in which to store information. SQL serves the same essential purpose as an Excel spreadsheet.

  • Newer Posts
  • 1
  • 2
  • 3
  • 4
  • 5
  • Older Posts

  • GitHub
  • Instagram
  • LinkedIn
  • RSS
  • Twitter

Looking for something?

Copyright 2023 Koren Leslie Cohen