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

SectionList - SectionSeparatorComponent #48507

Closed
GaelCO opened this issue Jan 6, 2025 · 2 comments
Closed

SectionList - SectionSeparatorComponent #48507

GaelCO opened this issue Jan 6, 2025 · 2 comments
Labels
Component: SectionList Type: Question Issues that are actually questions and not bug reports.

Comments

@GaelCO
Copy link

GaelCO commented Jan 6, 2025

Description

When I use a SectionSeparatorComponent, I expect the separator is between each section.
But, it displays between each section, as well as between the title and the items in the section.
If I wanted this behavior, I would have added a separator in the SectionHeader.

Is this the desired behavior?
Is there a clean way to handle a separator between sections?

NB : test on android and with expo:snack

Steps to reproduce

  • add a SectionList with some sections. Have a header and sub items. Use SectionSeparatorComponent.
  • launch app

React Native Version

0.76.5

Affected Platforms

Runtime - Android, Runtime - iOS, Runtime - Web

Output of npx react-native info

System:
  OS: Linux 6.8 Ubuntu 24.04.1 LTS 24.04.1 LTS (Noble Numbat)
  CPU: (16) x64 AMD Ryzen 7 7730U with Radeon Graphics
  Memory: 15.72 GB / 30.66 GB
  Shell:
    version: 5.2.21
    path: /bin/bash
Binaries:
  Node:
    version: 22.11.0
    path: ~/.nvm/versions/node/v22.11.0/bin/node
  Yarn:
    version: 4.6.0
    path: ~/.nvm/versions/node/v22.11.0/bin/yarn
  npm:
    version: 10.9.0
    path: ~/.nvm/versions/node/v22.11.0/bin/npm
  Watchman: Not Found
SDKs:
  Android SDK: Not Found
IDEs:
  Android Studio: Not Found
Languages:
  Java:
    version: 17.0.13
    path: /usr/bin/javac
  Ruby: Not Found
npmPackages:
  "@react-native-community/cli":
    installed: 15.1.3
    wanted: 15.1.3
  react:
    installed: 18.3.1
    wanted: 18.3.1
  react-native:
    installed: 0.76.5
    wanted: 0.76.5
npmGlobalPackages:
  "*react-native*": Not Found
Android:
  hermesEnabled: true
  newArchEnabled: true
iOS:
  hermesEnabled: true
  newArchEnabled: false

Stacktrace or Logs

none

Reproducer

https://snack.expo.dev/@gco/sectionlist

Screenshots and Videos

No response

@cortinico cortinico added Type: Question Issues that are actually questions and not bug reports. and removed Needs: Triage 🔍 labels Jan 6, 2025
@react-native-bot
Copy link
Collaborator

Note

Not a bug report: This issue looks like a question. We are using GitHub issues exclusively to track bugs in React Native. GitHub may not be the ideal place to ask a question, but you can try asking over on Stack Overflow, or on Reactiflux.

@GaelCO
Copy link
Author

GaelCO commented Jan 6, 2025

hi,

It's not a bug. I find a way with separators.updateProps

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: SectionList Type: Question Issues that are actually questions and not bug reports.
Projects
None yet
Development

No branches or pull requests

3 participants