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

Add ability to send in height or width of the item #181

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

iamajoe
Copy link

@iamajoe iamajoe commented Jan 5, 2020

The feature came from a necessity of having different height items. When that happened, sorting the list would cause discrepancies in size because it was checking the rowsLayout with an old height. This helps base the height on something we might already have at the data level. The PR could still benefit from overriding the rowsLayout item itself since it would be more performant aswell to not calculate these values when we already have them but I'm new to the project and I implemented the MVP.

Here is an example usage:

const data = [
  { text: 'Foo', height: 10 },
  { text: 'Bar' }
];

The first data item would have a height as the basis and the second would one would be calculated.

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.

None yet

1 participant