Count of Taxonomy

I would like to get a total count of instances of a specific taxonomy. Below is my current code.

{% set taxlist = taxonomylist.get() %} {% if taxlist %}
<div class="tags">
    {% for tax,value in taxlist[taxonomy] %} {% set active = uri.param(taxonomy) == tax ? 'active' : '' %}
    <li><a class="{{ active }}" href="{{ base_url_absolute }}/filter/{{ taxonomy }},{{ config.system.param_sep }},{{ tax }}">{{ tax|capitalize }} {{taxlist|count}}</a></li> {% endfor %}
</div> {% endif %} 

I see that

{{ dump(taxonomylist)}}

Does output:

  "tag" => array:6 [
      "manager" => 3
      "testing" => 1
      "technical" => 1
      "hardening standard" => 1
      "data classification" => 1
      "techical" => 1
---

I was able to figure this out. For the newbies out these who might want to reuse this code:


{% set taxlist = taxonomylist.get() %} {% if taxlist %}
<div class="tags">
    {% for tax, value in taxlist[taxonomy]|ksort %} {% set active = uri.param(taxonomy) == tax ? 'active' : '' %}
    <li><a class="{{ active }}" href="{{ base_url_absolute }}/filter/{{ taxonomy }},{{ config.system.param_sep }},{{ tax }}">{{ tax|capitalize }} ({{value}})</a></li> {% endfor %}
</div> {% endif %},{{ dump(taxlist)}}

I added the …({{value}})… portion of the code to add the count for a specific taxonomy.