Welcome to mirror list, hosted at ThFree Co, Russian Federation.

search.js « search « frontend « content - gitlab.com/gitlab-org/gitlab-docs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 5ea8a87a516847841eac803b7f137e7de7b63c60 (plain)
1
2
3
4
5
6
7
8
9
10
11
/**
 * Functions used by both DocSearch and InstantSearch.
 */

export const getDocsVersion = () => {
  let docsVersion = 'main';
  if (document.querySelector('meta[name="docsearch:version"]').content.length > 0) {
    docsVersion = document.querySelector('meta[name="docsearch:version"]').content;
  }
  return docsVersion;
};