Skip to content

typo ammendment #27

Merged
merged 1 commit into from
Oct 26, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion 05 JavaScript.md
Original file line number Diff line number Diff line change
Expand Up @@ -685,7 +685,7 @@ const matt = new ECMA6Student('matt')
console.log(ECMA6Student.studentCount()) // prints '2'
```

Notice that the static vsriable `count` is public (so the `studentCount()` method is somewhat superfluous in this example!). This highlights one of the limitations of JavaScript, the lack of a simple way to define private attributes (variables and methods). The next section goes into this in more detail and explains some workarounds (hacks) to get around this.
Notice that the static variable `count` is public (so the `studentCount()` method is somewhat superfluous in this example!). This highlights one of the limitations of JavaScript, the lack of a simple way to define private attributes (variables and methods). The next section goes into this in more detail and explains some workarounds (hacks) to get around this.

### 4.5 Handling Data Encapsulation

Expand Down