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(hippy-react-web): fixed image newProps src unRendered problem #472

Merged
merged 6 commits into from
Dec 31, 2020

Conversation

wanghaooo
Copy link
Contributor

@wanghaooo wanghaooo commented Dec 30, 2020

Before submitting a new pull request, please make sure:

  • Test cases have been added/updated for the code you will submit.
  • Documentation has added or updated.
  • Commit message is following the Convention Commit guideline.
  • Squash the repeat code commits, short patches are welcome.

@codecov-io
Copy link

codecov-io commented Dec 30, 2020

Codecov Report

Merging #472 (336f636) into master (4ffc3e3) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #472   +/-   ##
=======================================
  Coverage   59.42%   59.42%           
=======================================
  Files          25       25           
  Lines        1676     1676           
=======================================
  Hits          996      996           
  Misses        680      680           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4ffc3e3...336f636. Read the comment docs.

@@ -100,6 +100,8 @@ export class Image extends React.Component {
super(props);
this.state = {
isLoadSuccess: false,
imageUrl: props.source ? props.source.uri : '',
prevImageUrl: props.source ? props.source.uri : '',
Copy link
Collaborator

Choose a reason for hiding this comment

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

props.source ? props.source.uri : '' 重复了写了两次,可以精简圈复杂度

@zoomchan-cxj zoomchan-cxj merged commit bfc657a into Tencent:master Dec 31, 2020
zoomchan-cxj pushed a commit that referenced this pull request Jan 4, 2021
* fix(hippy-react-web): fixed image newProps src unRendered problem

* fix(hippy-react-web): fixed eslint problem

* fix(hippy-react-web): use getDerivedStateFromProps replace componentWillReceiveProps

* fix(hippy-react-web): life cycle replace

* chore(hippy-react-web): optimize the code
boxizen pushed a commit to boxizen/Hippy that referenced this pull request Aug 16, 2021
…ncent#472)

* fix(hippy-react-web): fixed image newProps src unRendered problem

* fix(hippy-react-web): fixed eslint problem

* fix(hippy-react-web): use getDerivedStateFromProps replace componentWillReceiveProps

* fix(hippy-react-web): life cycle replace

* chore(hippy-react-web): optimize the code
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