Deprecations page and filters

Copy over the Deprecations filter Vue component and related JS, and ensure the page functions on the Hugo site.

Deprecations code: https://gitlab.com/gitlab-org/gitlab-docs/-/tree/main/content/frontend/deprecations?ref_type=heads

Deprecations page (Hugo): https://gitlab-org.gitlab.io/technical-writing-group/gitlab-docs-hugo/update/deprecations/

Nanoc version: https://docs.gitlab.com/ee/update/deprecations.html

Note that we also need to figure out how to create the GITLAB_RELEASE_DATES JS variable here. This data comes from a JS file hosted on gitlab.com (this).

For Nanoc, we create it on-build with this function: https://gitlab.com/gitlab-org/gitlab-docs/-/blob/main/lib/helpers/generic.rb#L206

Not sure how the best way to do this in Hugo will be, but it will need to be similar: fetch the YML, convert it to JSON, output it as a variable in the template that's usable by our JS code.

Implementation steps

  • Copy over deprecations.js and deprecation_filters.vue
  • Set deprecations.js up to load only on the deprecations page (Nanoc logic here)
  • Fetch releases.yml on build and output its data as a JSON object (GITLAB_RELEASE_DATES variable)
Edited by Sarah German