expressjs / expressjs/cookie-parser
Replace `var` with `let` and `const`
- Dominant language
- JavaScript
- Stars
- 2k
- Forks
- 234
- PR merge metrics
- No merged PRs in 30d
Description
### Description
According to [the docs](https://www.w3schools.com/js/js_variables.asp), using `var` is not recommended, unless it's necessary, It would be useful to replace `var` in `index.js` with `let` or `const` depending on their scope and usage. And also as it's less error-prone, this change can make the code more robust for the possible future code change.
### Task
- Replace `var` with `let` or `const` in `index.js` file
- Update`var` with `let` or `const` in `README.md` file
### Supporting Docs and Articles
[w3schools variables](https://www.w3schools.com/js/js_variables.asp)
[Why don’t we use `var` anymore?](https://medium.com/@codingsam/awesome-javascript-no-more-var-working-title-999428999994)
Contributor guide
Assessment
This issue has not been assessed yet.