diff --git a/gitlab-pages/website/src/theme/DocPage/index.js b/gitlab-pages/website/src/theme/DocPage/index.js index 5c2f21044..69d441f9d 100644 --- a/gitlab-pages/website/src/theme/DocPage/index.js +++ b/gitlab-pages/website/src/theme/DocPage/index.js @@ -59,7 +59,10 @@ function DocPage(props) { sidebar={sidebar} sidebarCollapsible={sidebarCollapsible} syntax={syntax} - onSyntaxChange={l => setSyntax(l)} + onSyntaxChange={l => { + localStorage.setItem('syntax', l); + setSyntax(l) + }} /> )}