Skip to content

Conversation

schoenwaldnils
Copy link
Contributor

As discussed in #31 here my implementation of const and let.

@vsemozhetbyt
Copy link
Contributor

Unfortunately, now we have at least two concurrent full attempts (#38 and #51) and two partial attempts (#33 and #44) to address the issue.

@schoenwaldnils
Copy link
Contributor Author

schoenwaldnils commented Jan 6, 2017

#33 is more an attempt to show the use of the variable-name, isn't it?
#44 is included in #51

#38 defaults to let.
In my understanding let only should be used where the variable is reassigned.
But constcan be alternated. (#50)
For example the eslint-decleration prefer-const

Copy link
Owner

@ryanmcdermott ryanmcdermott left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is looking great! Make these changes and I think this is good to go, unless anyone has objections. Thanks so much for taking the time to make all of this consistent. I appreciate your constant support ;)

README.md Outdated

it('handles leap year', function() {
let date = new MakeMomentJSGreatAgain('2/1/2016');
cosnt date = new MakeMomentJSGreatAgain('2/1/2016');
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be const

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

my bad :D

README.md Outdated

it('handles non-leap year', function() {
let date = new MakeMomentJSGreatAgain('2/1/2015');
cosnt date = new MakeMomentJSGreatAgain('2/1/2015');
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be const

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is fixed now

This was referenced Jan 7, 2017
Nils Schönwald added 2 commits January 7, 2017 15:06
* 'master' of github.com:ryanmcdermott/clean-code-javascript:
  Add: Error Handling Section
  Correct spelling of Cessna airplane
  Adjusted the commentthat show the result
@ryanmcdermott ryanmcdermott merged commit 62f0b70 into ryanmcdermott:master Jan 8, 2017
@ryanmcdermott
Copy link
Owner

This looks great! Since sadly the examples in this document aren't testable (maybe we could find a way in the future), I assume that everything here works after reading it as carefully as I could. If anyone sees anything else that stands out with these changes, open an issue or ideally a PR 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants