Skip to content

Add failing test about module component#4109

Closed
vslinko wants to merge 1 commit into
masterfrom
unknown repository
Closed

Add failing test about module component#4109
vslinko wants to merge 1 commit into
masterfrom
unknown repository

Conversation

@vslinko

@vslinko vslinko commented Jun 12, 2015

Copy link
Copy Markdown

Module pattern components like
function Component(props) { return { render() { return <div /> } } }
doesn't update when props changed.

This behaviour looks like a buggy. Am I right?

@vslinko

vslinko commented Jun 12, 2015

Copy link
Copy Markdown
Author

@zpao

zpao commented Jun 15, 2015

Copy link
Copy Markdown
Contributor

cc @sebmarkbage

@dittos

dittos commented Jun 17, 2015

Copy link
Copy Markdown
Contributor

The first parameter of constructor is initial props, so props.test should become this.props.test. The module pattern example in the blog post also named the first argument initialProps.

@vslinko

vslinko commented Jun 17, 2015

Copy link
Copy Markdown
Author

@dittos Hmm, you're right.
So, this test isn't valid and could be closed.

@sebmarkbage sebmarkbage closed this Oct 6, 2015
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.

5 participants