>
            {% assign page_url = page.url | prepend: site.baseurl %}
            {% for link in links %}
            <li class="nav-item">
                {% assign cur_url = link.link | remove: "index.html" %}
                {% if page_url == link.link or page_url == cur_url %}
                {% include link.html link=link class="btn nav-link active" %}
                {% else %}
                {% include link.html link=link class="btn nav-link" %}
                {% endif %}
            </li>
       