Closed industrian closed 2 years ago
@industrian I think I have a potential culprit, which is due to lack of proper documentation in the kit:
https://commercetools-docs-kit.vercel.app/documentation/configuration/setup#folder-structure (nearest heading, it does not directly have to do with this)
The additionalPrismLanguages
configuration flag was never actually set in the conent repository, that means it relies on whatever Prism (the syntax highlighter library) ships built-in in any given version. The kit smoke test explicitly sets the supported languages so I guess it is a regression with some prism version that went undetected in the kit repo but popped up in your case.
content repo: https://github.com/commercetools/commercetools-docs/blob/main/packages/gatsby-theme-docs-base/configure-theme.js#L7 (not public just in case someone wonders)
@timonrey if the above turns out true another sign we should simplify the package and configuration structure and invest significantly more into documentation.
@nkuehn
Defining the additionalPrismLanguages
in gatsby-config.js has added code highlighting, as below (running locally):
great, thank you for the fast feedback!
In the docs smoke test, Java code examples are highlighted: https://commercetools-docs-kit.vercel.app/docs-smoke-test/views/code-examples#java
In the docs website they're not. This is regardless of them being a code example from a file or in a code block.
Another good example being the current Java SDK page.
I was testing with the example code in the docs smoke test, but as you can see above it also affects any Java code: