<%# --------------------------------------------------------------- # docmd : the zero-config documentation engine. # @website https://docmd.io # [docmd-source] - Please do not remove this header. # --------------------------------------------------------------- %> <% if (versions && versions.all.length > 0) { const current = activeVersion || versions.all.find(v => v.id === versions.current); // If we are in a sub-version (e.g. /v1/), we go up one level (../) to get to root. const isCurrentSubVersion = current && current.id !== versions.current; const upOneLevel = isCurrentSubVersion ? '../' : ''; %>
<% } %>