#markup is replacing colon in <gcse:search... tag with space I have the following code:

 return array(
      '#type' =&gt; 'markup',
      '#markup' =&gt; '&lt;gcse:search queryParameterName="query" resultsUrl="'
        . Url::fromRoute('cn.search', [], ['absolute' =&gt; TRUE])-&gt;toString()
        . '"&gt;&lt;/gcse:search&gt;',
      '#allowed_tags' =&gt; ['gcse', 'gcse:search'],
    );


but the output is:

  &lt;gcse search queryparametername="query" resultsurl="http://d8.constitutionnet.org/search2"&gt;&lt;/gcse&gt;


How do I prevent the colon being converted to a space?
Use an inline template:

  return [
    '#type' =&gt; 'inline_template',
    '#template' =&gt; '&lt;gcse:search queryParameterName="query" resultsUrl="{{ url }}"&gt;&lt;/gcse:search&gt;',
    '#context' =&gt; [
      'url' =&gt; Url::fromRoute('cn.search', [], ['absolute' =&gt; TRUE]),
    ],
  ];