Skip to content

Re-add hook property

Sarah German requested to merge 78-missing-mermaid into main

What does this MR do and why?

Fixes a regression introduced in !78 (merged).

We need to keep the hook: "writeBundle", configuration for rollup-plugin-copy in order to copy mermaid.min.js into the vite directory. If we don't specify the hook, that directory does not exist when the copy runs, and so mermaid is not included in the build.

Closes #78 (closed)

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

  1. Configure a local GitLab Docs environment: https://gitlab.com/gitlab-org/technical-writing-group/gitlab-docs-hugo/-/blob/main/doc/setup.md.
  2. Run make clean to remove old assets
  3. Run make view and verify you can load a mermaid chart, like this one: http://localhost:1313/administration/self_hosted_models/#self-hosted-models-compared-to-the-default-gitlab-ai-vendor-architecture

Merge request acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Merge request reports