Skip to content

Favor stateless functions over classes when there's no state - #688

Merged
ljharb merged 3 commits into
airbnb:masterfrom
joaomilho:patch-2
Jan 21, 2016
Merged

ljharb merged 3 commits into
airbnb:masterfrom
joaomilho:patch-2

Conversation

@joaomilho

Copy link
Copy Markdown
Contributor

No description provided.

Comment thread react/README.md Outdated

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

there should always be a space between ) and {

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

solved.

@ljharb ljharb changed the title Favour stateless functions over classes when there's no state Favor stateless functions over classes when there's no state Jan 20, 2016
@ljharb

ljharb commented Jan 20, 2016

Copy link
Copy Markdown
Collaborator

Thanks, this looks great pending a few comments.

It would be ideal if there was a linter rule that could help enforce this, although it may not be possible.

Comment thread react/README.md

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

it's unfortunate that this will break the link - however since the title on line 28 didn't change, are you sure this link works now?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

now it works :D

- Space between function name and args;
- use `render(){}` syntax in object literal;
- Fix link to section;
@joaomilho

Copy link
Copy Markdown
Contributor Author

It's all fixed.

ljharb added a commit that referenced this pull request Jan 21, 2016
[guide] Favor stateless functions over classes when there's no state
@ljharb
ljharb merged commit 06746fa into airbnb:master Jan 21, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants