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

Bug: use keyToListDimensionsMap instead of indexKey to find item dimension first. #45

Open
ryuever opened this issue Sep 17, 2023 · 0 comments

Comments

@ryuever
Copy link
Member

ryuever commented Sep 17, 2023

To Reproduce

const useMountItem = props => {
  if (initialRef.current) {
    const { remover, dimensions: itemDimensions } = dimensions.registerItem(
      itemKey,
      {
        ignoredToPerBatch,
        recyclerType,
      },
    );
    disposerRef.current = remover;
    // @ts-ignore
    itemDimensionsRef.current = itemDimensions

    initialRef.current = false;
  }

  useMemo(() => {
    // itemMeta will be null
    const itemMeta = dimension.getFinalKeyMeta(itemKey)
  }, [])
}
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

No branches or pull requests

1 participant