Skip to content

hpi-schul-cloud/schulcloud-documentation

Repository files navigation

Website

This website is a documentation aggregator for all Schulcloud-Verbund software.

It is deployed at https://documentation.dbildungscloud.dev/

This website is built using Docusaurus 3.7, a modern static website generator.

Installation

$ npm ci

Local Development

$ npm run start

This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server.

Note that the search will only work with the build command.

Build

$ npm run build

This command generates static content into the build directory and can be served using any static contents hosting service.

Update the docs

Create a new branch. Change the /docs files.

Check for errors

Please make sure that code examples are valid code and watch out for typos even in your text. Use your IDE for support.

Deployment

Create a pull request and once your changes are merged into main the website will automatically deploy the new version.

Important

Do not remove the branch gh-pages. This branch is auto generated and contains the hosted website.

Troubleshooting

SVG Warnings

There are cases where you get warnings from .SVG files exported from Draw.io.

The warning indicates that Docusaurus is unable to process the .svg files generated by Draw.io. This is likely because the .svg files contain embedded metadata or unsupported elements that Docusaurus cannot handle.

There are two easy methods to solve this:


1. Export Clean SVGs from Draw.io

  • Open the .drawio file in Draw.io.
  • Export the diagram as an SVG:
    • Go to File > Export As > SVG.
    • In the export dialog, ensure the following options are checked:
      • Include a copy of my diagram (uncheck this if it's checked).
      • Transparent background (optional).
    • Save the file.

This will generate a cleaner SVG file that Docusaurus can process.


2. Optimize the SVG Files

Use an SVG optimization tool like SVGO to clean up the SVG files and remove unnecessary metadata.

  • Install SVGO globally:
    npm install -g svgo
  • Optimize the SVG files:
    svgo /path/to/Create_TLDRAW.drawio.svg
    svgo /path/to/Delete_TLDRAW.drawio.svg

This will produce optimized SVGs that are more likely to work with Docusaurus.

To optimize all SVGs in the current project you can just use a simple one-line script:

find . -name '*.svg' -exec npx svgo {} \;

Don't forget to test the build

After making the changes, rebuild your Docusaurus project:

npm run build

Verify that the warnings are resolved.

About

Documentation for the schul-cloud

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 22