Skip to content

Commit fb65b9a

Browse files
committed
[guide] fix a few IIFE examples
1 parent 018dd6e commit fb65b9a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1936,13 +1936,13 @@ Other Style Guides
19361936
(() => {
19371937
const name = 'Skywalker';
19381938
return name;
1939-
})();
1939+
}());
19401940
19411941
// good (guards against the function becoming an argument when two files with IIFEs are concatenated)
19421942
;(() => {
19431943
const name = 'Skywalker';
19441944
return name;
1945-
})();
1945+
}());
19461946
```
19471947
19481948
[Read more](http://stackoverflow.com/questions/7365172/semicolon-before-self-invoking-function/7365214%237365214).

0 commit comments

Comments
 (0)