Skip to content

Commit 8bb4ea4

Browse files
committed
simple and complex properties
1 parent c18d8e1 commit 8bb4ea4

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/index.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,11 @@ console.log(drink.getDrinkDetails());
2222

2323
// logging properties uses the key
2424
console.log(drink['complex property']);
25+
console.log(drink.name);
2526

2627
/**
2728
* KV Pairs are stored like 'key': 'value' so both works
2829
* the use of the space requires the '' within the key
29-
* logging properties uses the key
30+
* logging complex properties uses the key
31+
* logging simple keys can use the key or dot notation
3032
*/

0 commit comments

Comments
 (0)