Skip to content

Commit 772f4ab

Browse files
committed
run prettier
1 parent a09f7df commit 772f4ab

1 file changed

Lines changed: 9 additions & 10 deletions

File tree

  • Sprint-3/1-key-errors

‎Sprint-3/1-key-errors/0.js‎

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,18 +3,17 @@
33

44
// call the function capitalise with a string input
55
// interpret the error message and figure out why an error is occurring
6-
//It says syntax error Identifier 'str' has already been declared.
7-
// function parameter and let which is inside the funtion can never
6+
//It says syntax error Identifier 'str' has already been declared.
7+
// function parameter and let which is inside the funtion can never
88
// be the same because both variables are in the same scope
99
// function capitalise(str) {
10-
//let str = `${str[0].toUpperCase()}${str.slice(1)}`;
11-
//return str;
10+
//let str = `${str[0].toUpperCase()}${str.slice(1)}`;
11+
//return str;
1212
//}
1313
//console.log(capitalise("error")
14-
//
15-
function capitalise(firstLetter){
16-
let str =`${firstLetter[0].toUpperCase()}${firstLetter.slice(1)}`
17-
return str;
14+
//
15+
function capitalise(firstLetter) {
16+
let str = `${firstLetter[0].toUpperCase()}${firstLetter.slice(1)}`;
17+
return str;
1818
}
19-
console.log(capitalise("error"));
20-
19+
console.log(capitalise("error"));

0 commit comments

Comments
 (0)