How to add space between items in Text List custom field?

Hi All,

The subtitle field for News entities is calling on a custom field called Authors, which is of the Text List type. As you can see in the screenshot below, there is no space between the two author’s names in the subtitle.

I tried adding a space at the end of each author’s name in the Knowledge Graph directly, but I believe the field trims any extra whitespace.

That being said, is it possible to add a " " between the items in the text list so the results in the example above would appear as follows “Goker Aydin, Tinglong Dai”?

Thank you,
Austin

1 Like

Hi Austin, how are you currently coding the subtitle?

I believe the following function should handle. If it’s not automatically adding the space, simple change the second parameter to ', '.

subtitle: profile => Formatter.joinList(profile.c_authors, ',').

Let me know if this helps.

1 Like

Hey Amani,

I didn’t realize there was a formatter for text lists, thank you for sharing! This looks great.

Best,
Austin