Skip to content

Commit 1183727

Browse files
authored
Merge pull request #1077 from egorzot/master
Fix a mistake in article
2 parents fce05f5 + 5e7a370 commit 1183727

File tree

1 file changed

+1
-1
lines changed
  • 1-js/09-classes/04-private-protected-properties-methods

1 file changed

+1
-1
lines changed

1-js/09-classes/04-private-protected-properties-methods/article.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -322,7 +322,7 @@ Hiding complexity
322322

323323
**It's always convenient when implementation details are hidden, and a simple, well-documented external interface is available.**
324324

325-
To hide internal interface we use either protected or public properties:
325+
To hide internal interface we use either protected or private properties:
326326

327327
- Protected fields start with `_`. That's a well-known convention, not enforced at the language level. Programmers should only access a field starting with `_` from its class and classes inheriting from it.
328328
- Private fields start with `#`. JavaScript makes sure we only can access those from inside the class.

0 commit comments

Comments
 (0)