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

[Request For Comments] fix: @flow flag does not need to be first comment #240

Merged
merged 1 commit into from
Jun 28, 2017

Conversation

scott-silver
Copy link
Contributor

@scott-silver scott-silver commented Jun 8, 2017

eslint-plugin-flowtype rules require that the // @flow comment be the first line of a file.

This is stricter than Flow requires (emphasis in original), which simply requires the comment appear before any code:

The Flow background process monitors all Flow files. However, how does it know which files are Flow files and, thus, should be checked? Placing the following before any code in a JavaScript file is the flag the process uses to answer that question.

1 // @flow

This PR updates noTypesMissingFileAnnotation to allows a comment to appear before the @flow comment.

This likely has more implications for requireValidFileAnnotation, however.

@scott-silver
Copy link
Contributor Author

ping @gajus

@julienw
Copy link

julienw commented Jun 29, 2017

thx ! Now I just need a new release :D

@gajus
Copy link
Owner

gajus commented Jun 30, 2017

The release is done automatically after the commit is merged.

@julienw
Copy link

julienw commented Jun 30, 2017

oh I see, thanks ! I didn't see any change to package.json, that's why I was confused.

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