Hi my goal is to query an api and show the results in a table, I have been using the UI kit category and the confluence macro template, the api query is successful but the table is always empty but confusingly when I use JSON.stringify to output it the data shows with no issue on the page but it doesn’t look very nice which is why I am trying to use a table. Would anyone be able to help me with this?
a simplified version of my code is
//various import statements
//various functions
const App =() =>{
const ans = useState(async () => await getStuff());
return(
<Fragment>
<Text> Stuff:{JSON.stringify(data, null,4)}</Text>
<Table>
<Head>
<Cell>
<Text> Column 1</Text>
</Cell>
......
......
</Head>
{data.map(issue => (
<Row>
<Cell>
<Text>{issue.c1}</Text>
</Cell>
....
....
</Row>))};
</Table>
</Fragment>);
};
export const run =render( <Macro app={<App />} />);