From 6213f9852a4f1906179a329bf95c31e49aa36228 Mon Sep 17 00:00:00 2001 From: Ka Lun Lee Date: Fri, 18 Mar 2016 00:07:22 -0700 Subject: [PATCH] added links for clarification on Make Objects Properties Private challenge. fixed grammar from previous PR. This closes #7282. --- .../object-oriented-and-functional-programming.json | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/challenges/01-front-end-development-certification/object-oriented-and-functional-programming.json b/challenges/01-front-end-development-certification/object-oriented-and-functional-programming.json index 82d1db23d5a..181d4dd0820 100644 --- a/challenges/01-front-end-development-certification/object-oriented-and-functional-programming.json +++ b/challenges/01-front-end-development-certification/object-oriented-and-functional-programming.json @@ -234,13 +234,14 @@ "title": "Make Object Properties Private", "description": [ "Objects have their own attributes, called properties, and their own functions, called methods.", - "In the previous challenges, we used the this keyword to reference public properties of the current object.", + "In the previous challenges, we used the this keyword to reference public properties of the current object.", "We can also create private properties and private methods, which aren't accessible from outside the object.", "To do this, we create the variable inside the constructor using the var keyword we're familiar with, instead of creating it as a property of this.", "This is useful for when we need to store information about an object but we want to control how it is used by outside code.", "For example, what if we want to store the speed our car is traveling at but we only want outside code to be able to modify it by accelerating or decelerating, so the speed changes in a controlled way?", "In the editor you can see an example of a Car constructor that implements this pattern.", - "Now try it yourself! Modify the Bike constructor to have a private property called gear and two public methods called getGear and setGear to get and set that value." + "Now try it yourself! Modify the Bike constructor to have a private property called gear and two public methods called getGear and setGear to get and set that value.", + "Further explanation on this keyword" ], "challengeSeed": [ "var Car = function() {",