How to send comma separated taxonomy term (as link to taxonomy term url ) from preprocess to twig file as single variable?
I have solved this like below : 

It was always considered as string so I have to send topics in from of array like below: 

$topics = array();
foreach($value['#row']-&gt;_entity-&gt;field_topic2 as $val){
  $topics[$val-&gt;entity-&gt;tid-&gt;value]= $val-&gt;entity-&gt;name-&gt;value;
}


And then in Twig I made links from them and it worked. 

&lt;div class="topics"&gt;
    {% for key,item in value.topics %}
        &lt;a href="{{ path('entity.taxonomy_term.canonical', {'taxonomy_term': key}) }}"&gt;{{item}}&lt;/a&gt;
        {% if not loop.last %},{% endif %} # for adding commas after each term
    {% endfor %}
&lt;/div&gt;