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

React: Fix rendering issue #109

Merged
merged 3 commits into from
Jan 20, 2023
Merged

React: Fix rendering issue #109

merged 3 commits into from
Jan 20, 2023

Conversation

reb-dev
Copy link
Collaborator

@reb-dev reb-dev commented Jan 20, 2023

#108

Previously, our arePropsEqual would only check if child props had changed for multiple children, but in the case of only one child it would always return true. This prevented the re-rendering of the child component even though it had updated props.

Added a new dev demo page based on #107 to reflect the change.

@reb-dev reb-dev requested a review from rokotyan January 20, 2023 01:14
@rokotyan rokotyan added this to the Release v1.0.3 milestone Jan 20, 2023
@reb-dev reb-dev requested a review from rokotyan January 20, 2023 18:48
@@ -4,7 +4,7 @@ import { Graph } from '@unovis/ts'
import { generateNodeLinkData, NodeDatum, LinkDatum } from '@src/utils/data'

export const title = 'Basic Graph'
export const subTitle = 'Generated Data'
export const subTitle = 'Select Node on Click'
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

@rokotyan Would you mind explaining how we should be labeling title, subTitle, and category? I want to be consistent but it's not clear to me the function of each one.

Copy link
Contributor

Choose a reason for hiding this comment

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

@reb-dev I would like them to give us a better understanding of what particular example is about. I don't have a clear guidance for that yet, so it's something we'll need to crystallize over time. If you have ideas, you're more than welcome to share them!

In the particular case:
Screen Shot 2023-01-20 at 12 04 27 PM
category tells us that it's a Graph example (I think this field will almost always be related to the component name);
title tells us that i'll be a rather basic example;
but subTitle give us an idea that there's something extra, i.e. node selection logic.

@rokotyan rokotyan merged commit f60657a into main Jan 20, 2023
@rokotyan rokotyan mentioned this pull request Feb 15, 2023
@rokotyan rokotyan deleted the fix/graph-nodes-selection branch May 22, 2023 19:58
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