Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

reorder class declarations #96

Merged
merged 1 commit into from
Jan 10, 2017
Merged

reorder class declarations #96

merged 1 commit into from
Jan 10, 2017

Conversation

vsemozhetbyt
Copy link
Contributor

@vsemozhetbyt vsemozhetbyt commented Jan 9, 2017

(Here comes a bunch of PRs after a code fragments mass test with ESLint checks and Node.js runnings.)

See no-use-before-define.

Class declarations are not hoisted. So 'keep the caller right above the callee' rule is less applicable here. Though the order of calls mitigates the danger of errors here, maybe in such a normative tip list this should be considered.

@ryanmcdermott ryanmcdermott merged commit 3f94eb2 into ryanmcdermott:master Jan 10, 2017
@ryanmcdermott
Copy link
Owner

Good deal, yes indeed hoisting doesn't apply to classes!

@vsemozhetbyt vsemozhetbyt deleted the no-use-before-define branch January 10, 2017 07:43
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.

2 participants