Purii / react-native-tableview-simple

Flexible and lightweight React Native component for UITableView made with pure CSS
https://snack.expo.io/@purii/react-native-tableview-simple
MIT License
535 stars 63 forks source link

Can't seem to make the detail prop work. #783

Closed Keeryel closed 10 months ago

Keeryel commented 10 months ago

I'm pretty sure the detail prop allows strings and is a text label that positions itself at the right of the tableview. I set the detail prop to a string of "Hello" to check whether I was right or not, but I couldn't seem to find any visual confirmation (Nothing showed up on my device). I decided to check the source code (of this repository) to see if I made a mistake, but I didn't see anything I didn't expect to find. I also tried reading the docs, but to no avail. Here is some replication information:

I was using Expo in a managed project I was testing using Expo Go on a physical iPhone device (iPhone 6s)

Expo Version: 49.0.7 React Native Version: 0.72.3 React Version: 18.2.0

This is the code with the tableview (this is basically the whole file)

const Settings = () => {
  return (
    <View>
      <TableView style={{ marginHorizontal: 15 }}>
        <Section roundedCorners hideSurroundingSeparators header="App Data">
          <Cell title="App Version" detail="1.0" />
          <Cell title="OS Version" />
        </Section>
      </TableView>
    </View>
  );
};

Any help is appreciated!

Keeryel commented 10 months ago

Oh I just found this property called cellStyle after looking through the source code for a bit. Using it seems to have fixed my problem. Hah.