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

Fix lint warnings, style fixups #2566

Merged
merged 1 commit into from
Nov 25, 2014
Merged

Fix lint warnings, style fixups #2566

merged 1 commit into from
Nov 25, 2014

Conversation

zpao
Copy link
Member

@zpao zpao commented Nov 19, 2014

Followup work for recent PRs

@zpao zpao changed the title Style nit fixups Fix lint warnings, style fixups Nov 19, 2014
@@ -43,7 +43,7 @@ var ReactDOMTextComponent = function(props) {
assign(ReactDOMTextComponent.prototype, {

/**
* @param {ReactText} node
* @param {ReactText} text
Copy link
Member Author

Choose a reason for hiding this comment

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

Our runtime typecheck transform fails here because it text and node don't match (more specifically, I think it will fail if you specify things in the docblock that aren't in the parameters, but not visa versa)

*
* Licensed under the Apache License, Version 2.0 (the "License");
Copy link
Collaborator

Choose a reason for hiding this comment

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

My bad, sorry.

@samccone
Copy link
Contributor

boom thanks :)

@zpao zpao force-pushed the style-fixup branch 3 times, most recently from 079fe29 to af1d6fd Compare November 25, 2014 22:57
@@ -101,7 +101,7 @@ function instantiateReactComponent(node, parentCompositeType) {
} else {
invariant(
false,
'Encountered invalid React node of type ' + typeof node
'Encountered invalid React node of type undefined, symbol, or boolean.'
Copy link
Member Author

Choose a reason for hiding this comment

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

We have a lint rule internally about invariant's second arg being a string literal. I'm not entirely sure why but I figured it's important enough to listen to.

Followup work for recent PRs
zpao added a commit that referenced this pull request Nov 25, 2014
Fix lint warnings, style fixups
@zpao zpao merged commit fd3f8e7 into facebook:master Nov 25, 2014
@zpao zpao deleted the style-fixup branch April 16, 2015 16:41
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