Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 3f5f2ca

Browse filesBrowse files
committed
work
1 parent 057783d commit 3f5f2ca
Copy full SHA for 3f5f2ca

File tree

Expand file treeCollapse file tree

324 files changed

+668
-285
lines changed
Open diff view settings
Filter options

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Dismiss banner
Expand file treeCollapse file tree

324 files changed

+668
-285
lines changed
Open diff view settings
Collapse file

‎…rison/1-comparison-questions/solution.md‎ ‎…rison/1-comparison-questions/solution.md‎1-js/2-first-steps/8-comparison/1-comparison-questions/solution.md renamed to 1-js/2-first-steps/08-comparison/1-comparison-questions/solution.md 1-js/2-first-steps/8-comparison/1-comparison-questions/solution.md renamed to 1-js/2-first-steps/08-comparison/1-comparison-questions/solution.md

Copy file name to clipboard
  • Display the source diff
  • Display the rich diff
File renamed without changes.
Collapse file

‎…omparison/1-comparison-questions/task.md‎ ‎…omparison/1-comparison-questions/task.md‎1-js/2-first-steps/8-comparison/1-comparison-questions/task.md renamed to 1-js/2-first-steps/08-comparison/1-comparison-questions/task.md 1-js/2-first-steps/8-comparison/1-comparison-questions/task.md renamed to 1-js/2-first-steps/08-comparison/1-comparison-questions/task.md

Copy file name to clipboard
  • Display the source diff
  • Display the rich diff
File renamed without changes.
Collapse file
  • Display the source diff
  • Display the rich diff
File renamed without changes.
Collapse file

‎…teps/9-uibasic/1-simple-page/solution.md‎ ‎…eps/09-uibasic/1-simple-page/solution.md‎1-js/2-first-steps/9-uibasic/1-simple-page/solution.md renamed to 1-js/2-first-steps/09-uibasic/1-simple-page/solution.md 1-js/2-first-steps/9-uibasic/1-simple-page/solution.md renamed to 1-js/2-first-steps/09-uibasic/1-simple-page/solution.md

Copy file name to clipboard
  • Display the source diff
  • Display the rich diff
File renamed without changes.
Collapse file
  • Display the source diff
  • Display the rich diff
File renamed without changes.
Collapse file

‎1-js/2-first-steps/15-function-expressions-arrows/article.md‎

Copy file name to clipboardExpand all lines: 1-js/2-first-steps/15-function-expressions-arrows/article.md
+3-3Lines changed: 3 additions & 3 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
In Javascript a function is not a "magical language structure", but a special kind of value.
44

5-
The syntax that we've used before is called *Function Declaration*:
5+
The syntax that we used before is called *Function Declaration*:
66

77
```js
88
function sayHi() {
@@ -87,8 +87,8 @@ let sayHi = function() {
8787
```
8888
8989
The answer is simple:
90-
- There's no need in `;` at the end of code blocks and syntax structures that use them like `if { ... }`, `for { }`, `function f { }` and alike.
91-
- A Function Expression appears in the context of the statement: `let sayHi = value;`. It's not a code block. The semicolon `;` is recommended at the end of statements, no matter what is the `value`. So the semicolon here is not related to Function Expression itself in any way, it just terminates the statement.
90+
- There's no need in `;` at the end of code blocks and syntax structures that use them like `if { ... }`, `for { }`, `function f { }` etc.
91+
- The Function Expression appears in the context of the statement: `let sayHi = value;`. It's not a code block. The semicolon `;` is recommended at the end of statements, no matter what is the `value`. So the semicolon here is not related to Function Expression itself in any way, it just terminates the statement.
9292
````
9393

9494

Collapse file

‎…-object2/2-is-empty/_js.view/solution.js‎ ‎…1-object/3-is-empty/_js.view/solution.js‎1-js/5-data-structures/4-object2/2-is-empty/_js.view/solution.js renamed to 1-js/3-object-basics/1-object/3-is-empty/_js.view/solution.js 1-js/5-data-structures/4-object2/2-is-empty/_js.view/solution.js renamed to 1-js/3-object-basics/1-object/3-is-empty/_js.view/solution.js

Copy file name to clipboard
File renamed without changes.
Collapse file

‎…es/4-object2/2-is-empty/_js.view/test.js‎ ‎…ics/1-object/3-is-empty/_js.view/test.js‎1-js/5-data-structures/4-object2/2-is-empty/_js.view/test.js renamed to 1-js/3-object-basics/1-object/3-is-empty/_js.view/test.js 1-js/5-data-structures/4-object2/2-is-empty/_js.view/test.js renamed to 1-js/3-object-basics/1-object/3-is-empty/_js.view/test.js

Copy file name to clipboard
File renamed without changes.
Collapse file
+11Lines changed: 11 additions & 0 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
Just loop over the object and `return false` immediately if there's at least one property.
2+
3+
```js
4+
function isEmpty(obj)
5+
for(let key in obj) {
6+
return false;
7+
}
8+
return true;
9+
}
10+
```
11+

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.