From 5ce3cf1c1c9a3a984b3085696088e52cce674ce8 Mon Sep 17 00:00:00 2001 From: Diego Colombo Date: Fri, 1 Sep 2023 17:02:43 +0200 Subject: [PATCH] handle array type in tabular data resource mapping --- .../TabularData/TabularDataResourceFormatter.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Microsoft.DotNet.Interactive.Formatting/TabularData/TabularDataResourceFormatter.cs b/src/Microsoft.DotNet.Interactive.Formatting/TabularData/TabularDataResourceFormatter.cs index 25b8bbd08b..c2c16cb009 100644 --- a/src/Microsoft.DotNet.Interactive.Formatting/TabularData/TabularDataResourceFormatter.cs +++ b/src/Microsoft.DotNet.Interactive.Formatting/TabularData/TabularDataResourceFormatter.cs @@ -155,6 +155,7 @@ public static TableSchemaFieldType ToTableSchemaFieldType(this Type type) => { } t when t == typeof(decimal?) => TableSchemaFieldType.Number, { } t when t == typeof(string) => TableSchemaFieldType.String, { } t when t == typeof(ReadOnlyMemory) => TableSchemaFieldType.String, + { IsArray: true } => TableSchemaFieldType.Array, _ => TableSchemaFieldType.Any }; } \ No newline at end of file