mirror of
https://github.com/wassname/optuna-dashboard.git
synced 2026-09-12 12:40:33 +08:00
Merge pull request #913 from nabenabe0928/debug/fix-csv-artifact-viewer
Fix an error in TableArtifactViewer when keys have an empty string
This commit is contained in:
@@ -55,7 +55,8 @@ export const TableArtifactViewer: React.FC<TableArtifactViewerProps> = (
|
||||
})
|
||||
const keys = Array.from(unionSet)
|
||||
return keys.map((key) => ({
|
||||
header: key,
|
||||
// ``header`` cannot be a falsy value, so replace key with a string looking like an empty string.
|
||||
header: key || " ",
|
||||
accessorFn: (info: Data) =>
|
||||
typeof info[key] === "object" ? JSON.stringify(info[key]) : info[key],
|
||||
enableSorting: true,
|
||||
|
||||
Reference in New Issue
Block a user